summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--maintainers/maintainer-list.nix5
-rw-r--r--pkgs/applications/editors/vim/configurable.nix255
-rw-r--r--pkgs/applications/editors/vim/qvim.nix180
-rw-r--r--pkgs/applications/networking/cluster/kubetail/default.nix30
-rw-r--r--pkgs/build-support/build-maven.nix5
-rw-r--r--pkgs/build-support/setup-hooks/remove-pytest-cache.sh1
-rw-r--r--pkgs/development/haskell-modules/configuration-common.nix3
-rw-r--r--pkgs/development/haskell-modules/configuration-nix.nix3
-rw-r--r--pkgs/development/interpreters/php/default.nix415
-rw-r--r--pkgs/development/libraries/libfilezilla/default.nix4
-rw-r--r--pkgs/development/libraries/pcl/default.nix11
-rw-r--r--pkgs/development/python-modules/pyserial/default.nix2
-rw-r--r--pkgs/development/python-modules/wxPython/4.0.nix41
-rw-r--r--pkgs/development/tools/dep/default.nix6
-rw-r--r--pkgs/development/tools/kustomize/default.nix28
-rw-r--r--pkgs/development/tools/misc/ycmd/default.nix8
-rw-r--r--pkgs/misc/vim-plugins/default.nix8
-rw-r--r--pkgs/os-specific/darwin/skhd/default.nix6
-rw-r--r--pkgs/os-specific/linux/fuse/default.nix8
-rw-r--r--pkgs/os-specific/linux/kernel/linux-4.14.nix4
-rw-r--r--pkgs/os-specific/linux/kernel/linux-4.17.nix4
-rw-r--r--pkgs/os-specific/linux/kernel/linux-4.4.nix4
-rw-r--r--pkgs/os-specific/linux/kernel/linux-4.9.nix4
-rw-r--r--pkgs/servers/monitoring/grafana/default.nix6
-rw-r--r--pkgs/stdenv/cross/default.nix1
-rw-r--r--pkgs/tools/admin/azure-cli/default.nix0
-rw-r--r--pkgs/tools/filesystems/simg2img/default.nix25
-rw-r--r--pkgs/tools/graphics/yaxg/default.nix38
-rw-r--r--pkgs/tools/misc/eot-utilities/default.nix2
-rw-r--r--pkgs/tools/networking/cntlm/default.nix10
-rw-r--r--pkgs/tools/security/cfssl/default.nix6
-rw-r--r--pkgs/tools/security/passff-host/default.nix36
-rw-r--r--pkgs/tools/system/bfs/default.nix2
-rw-r--r--pkgs/tools/system/bfs/tests.patch10
-rw-r--r--pkgs/top-level/all-packages.nix19
35 files changed, 622 insertions, 568 deletions
diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix
index a51183e727d4..5a13e97b6857 100644
--- a/maintainers/maintainer-list.nix
+++ b/maintainers/maintainer-list.nix
@@ -2737,6 +2737,11 @@
     github = "neeasade";
     name = "Nathan Isom";
   };
+  neonfuz = {
+    email = "neonfuz@gmail.com";
+    github = "neonfuz";
+    name = "Sage Raflik";
+  };
   nequissimus = {
     email = "tim@nequissimus.com";
     github = "nequissimus";
diff --git a/pkgs/applications/editors/vim/configurable.nix b/pkgs/applications/editors/vim/configurable.nix
index ad04cab62f51..da15081173da 100644
--- a/pkgs/applications/editors/vim/configurable.nix
+++ b/pkgs/applications/editors/vim/configurable.nix
@@ -1,7 +1,7 @@
 # TODO tidy up eg The patchelf code is patching gvim even if you don't build it..
 # but I have gvim with python support now :) - Marc
 args@{ source ? "default", callPackage, fetchurl, stdenv, ncurses, pkgconfig, gettext
-, composableDerivation, writeText, lib, config, glib, gtk2, gtk3, python, perl, tcl, ruby
+, writeText, lib, config, glib, gtk2, gtk3, python, perl, tcl, ruby
 , libX11, libXext, libSM, libXpm, libXt, libXaw, libXau, libXmu
 , libICE
 , vimPlugins
@@ -10,13 +10,27 @@ args@{ source ? "default", callPackage, fetchurl, stdenv, ncurses, pkgconfig, ge
 # apple frameworks
 , CoreServices, CoreData, Cocoa, Foundation, libobjc, cf-private
 
-, wrapPythonDrv ? false
-
+, features          ? "huge" # One of tiny, small, normal, big or huge
+, wrapPythonDrv     ? false
+, guiSupport        ? config.vim.gui or "auto"
+, luaSupport        ? config.vim.lua or true
+, perlSupport       ? config.vim.perl or false      # Perl interpreter
+, pythonSupport     ? config.vim.python or true     # Python interpreter
+, rubySupport       ? config.vim.ruby or true       # Ruby interpreter
+, nlsSupport        ? config.vim.nls or false       # Enable NLS (gettext())
+, tclSupport        ? config.vim.tcl or false       # Include Tcl interpreter
+, multibyteSupport  ? config.vim.multibyte or false # Enable multibyte editing support
+, cscopeSupport     ? config.vim.cscope or true     # Enable cscope interface
+, netbeansSupport   ? config.netbeans or true       # Enable NetBeans integration support.
+, ximSupport        ? config.vim.xim or true        # less than 15KB, needed for deadkeys
+# By default, compile with darwin support if we're compiling on darwin, but
+# allow this to be disabled by setting config.vim.darwin to false
+, darwinSupport     ? stdenv.isDarwin && (config.vim.darwin or true) # Enable Darwin support
+, ftNixSupport      ? config.vim.ftNix or true      # Add .nix filetype detection and minimal syntax highlighting support
 , ... }: with args;
 
 
 let
-  inherit (args.composableDerivation) composableDerivation edf;
   nixosRuntimepath = writeText "nixos-vimrc" ''
     set nocompatible
     syntax on
@@ -48,148 +62,113 @@ let
   '';
 
   common = callPackage ./common.nix {};
-in
-composableDerivation {
-} (fix: rec {
-
-    name = "vim_configurable-${version}";
-
-    inherit (common) version postPatch hardeningDisable enableParallelBuilding meta;
-
-    src = builtins.getAttr source {
-      "default" = common.src; # latest release
-
-      "vim-nox" =
-          {
-            # vim nox branch: client-server without X by uing sockets
-            # REGION AUTO UPDATE: { name="vim-nox"; type="hg"; url="https://code.google.com/r/yukihironakadaira-vim-cmdsrv-nox/"; branch="cmdsrv-nox"; }
-            src = (fetchurl { url = "http://mawercer.de/~nix/repos/vim-nox-hg-2082fc3.tar.bz2"; sha256 = "293164ca1df752b7f975fd3b44766f5a1db752de6c7385753f083499651bd13a"; });
-            name = "vim-nox-hg-2082fc3";
-            # END
-          }.src;
-      };
-
-    patches = [ ./cflags-prune.diff ];
-
-    configureFlags
-      = [ "--enable-gui=${args.gui}" "--with-features=${args.features}" ];
-
-    nativeBuildInputs = [ pkgconfig ];
-
-    buildInputs
-      = [ ncurses libX11 libXext libSM libXpm libXt libXaw libXau
-          libXmu glib libICE ] ++ (if args.gui == "gtk3" then [gtk3] else [gtk2]);
-
-    # most interpreters aren't tested yet.. (see python for example how to do it)
-    flags = {
-        ftNix = {
-          patches = [ ./ft-nix-support.patch ];
-          preConfigure = ''
-            cp ${vimPlugins.vim-nix.src}/ftplugin/nix.vim runtime/ftplugin/nix.vim
-            cp ${vimPlugins.vim-nix.src}/indent/nix.vim runtime/indent/nix.vim
-            cp ${vimPlugins.vim-nix.src}/syntax/nix.vim runtime/syntax/nix.vim
-          '';
-        };
-      }
-      // edf {
-        name = "darwin";
-        enable = {
-          buildInputs = [ CoreServices CoreData Cocoa Foundation libobjc cf-private ];
-          NIX_LDFLAGS = stdenv.lib.optional stdenv.isDarwin
-            "/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation";
-        };
-      } #Disable Darwin (macOS) support.
-      // edf { name = "xsmp"; } #Disable XSMP session management
-      // edf { name = "xsmp_interact"; } #Disable XSMP interaction
-      // edf { name = "mzscheme"; feat = "mzschemeinterp";} #Include MzScheme interpreter.
-      // edf { name = "perl"; feat = "perlinterp"; enable = { nativeBuildInputs = [perl]; };} #Include Perl interpreter.
-
-      // edf {
-        name = "python";
-        feat = "python${if python ? isPy3 then "3" else ""}interp";
-        enable = {
-          buildInputs = [ python ];
-        } // lib.optionalAttrs wrapPythonDrv {
-          nativeBuildInputs = [ makeWrapper ];
-          postInstall = ''
-            wrapProgram "$out/bin/vim" --prefix PATH : "${python}/bin"
-          '';
-        } // lib.optionalAttrs stdenv.isDarwin {
-          configureFlags
-            = [ "--enable-python${if python ? isPy3 then "3" else ""}interp=yes"
-                "--with-python${if python ? isPy3 then "3" else ""}-config-dir=${python}/lib"
-                "--disable-python${if python ? isPy3 then "" else "3"}interp" ];
-        };
-      }
-
-      // edf { name = "tcl"; feat = "tclinterp"; enable = { buildInputs = [tcl]; }; } #Include Tcl interpreter.
-      // edf { name = "ruby"; feat = "rubyinterp"; enable = { buildInputs = [ruby]; };} #Include Ruby interpreter.
-      // edf {
-        name = "lua";
-        feat = "luainterp";
-        enable = {
-          buildInputs = [lua];
-          configureFlags = [
-            "--with-lua-prefix=${args.lua}"
-            "--enable-luainterp"
-          ];
-        };
-      }
-      // edf { name = "cscope"; } #Include cscope interface.
-      // edf { name = "workshop"; } #Include Sun Visual Workshop support.
-      // edf { name = "netbeans"; } #Disable NetBeans integration support.
-      // edf { name = "sniff"; feat = "sniff" ; } #Include Sniff interface.
-      // edf { name = "multibyte"; } #Include multibyte editing support.
-      // edf { name = "hangulinput"; feat = "hangulinput" ;} #Include Hangul input support.
-      // edf { name = "xim"; } #Include XIM input support.
-      // edf { name = "fontset"; } #Include X fontset output support.
-      // edf { name = "acl"; } #Don't check for ACL support.
-      // edf { name = "gpm"; } #Don't use gpm (Linux mouse daemon).
-      // edf { name = "nls"; enable = {nativeBuildInputs = [gettext];}; } #Don't support NLS (gettext()).
-      ;
-
-  cfg = {
-    luaSupport       = config.vim.lua or true;
-    pythonSupport    = config.vim.python or true;
-    rubySupport      = config.vim.ruby or true;
-    nlsSupport       = config.vim.nls or false;
-    tclSupport       = config.vim.tcl or false;
-    multibyteSupport = config.vim.multibyte or false;
-    cscopeSupport    = config.vim.cscope or true;
-    netbeansSupport  = config.netbeans or true; # eg envim is using it
-    ximSupport       = config.vim.xim or true; # less than 15KB, needed for deadkeys
-
-    # by default, compile with darwin support if we're compiling on darwin, but
-    # allow this to be disabled by setting config.vim.darwin to false
-    darwinSupport    = stdenv.isDarwin && (config.vim.darwin or true);
-
-    # add .nix filetype detection and minimal syntax highlighting support
-    ftNixSupport     = config.vim.ftNix or true;
-  };
 
-  #--enable-gui=OPTS     X11 GUI default=auto OPTS=auto/no/gtk/gtk2/gtk3/gnome/gnome2/motif/athena/neXtaw/photon/carbon
-    /*
-      // edf "gtk_check" "gtk_check" { } #If auto-select GUI, check for GTK default=yes
-      // edf "gtk2_check" "gtk2_check" { } #If GTK GUI, check for GTK+ 2 default=yes
-      // edf "gnome_check" "gnome_check" { } #If GTK GUI, check for GNOME default=no
-      // edf "motif_check" "motif_check" { } #If auto-select GUI, check for Motif default=yes
-      // edf "athena_check" "athena_check" { } #If auto-select GUI, check for Athena default=yes
-      // edf "nextaw_check" "nextaw_check" { } #If auto-select GUI, check for neXtaw default=yes
-      // edf "carbon_check" "carbon_check" { } #If auto-select GUI, check for Carbon default=yes
-      // edf "gtktest" "gtktest" { } #Do not try to compile and run a test GTK program
-    */
+  isPython3 = python.isPy3 or false;
 
-  preInstall = ''
-    mkdir -p $out/share/applications $out/share/icons/{hicolor,locolor}/{16x16,32x32,48x48}/apps
-  '';
+in stdenv.mkDerivation rec {
+
+  name = "vim_configurable-${version}";
+
+  inherit (common) version postPatch hardeningDisable enableParallelBuilding meta;
 
-  postInstall = stdenv.lib.optionalString stdenv.isLinux ''
+  src = builtins.getAttr source {
+    "default" = common.src; # latest release
+
+    "vim-nox" =
+      {
+        # vim nox branch: client-server without X by uing sockets
+        # REGION AUTO UPDATE: { name="vim-nox"; type="hg"; url="https://code.google.com/r/yukihironakadaira-vim-cmdsrv-nox/"; branch="cmdsrv-nox"; }
+        src = (fetchurl { url = "http://mawercer.de/~nix/repos/vim-nox-hg-2082fc3.tar.bz2"; sha256 = "293164ca1df752b7f975fd3b44766f5a1db752de6c7385753f083499651bd13a"; });
+        name = "vim-nox-hg-2082fc3";
+        # END
+      }.src;
+  };
+
+  patches = [ ./cflags-prune.diff ] ++ stdenv.lib.optional ftNixSupport ./ft-nix-support.patch;
+
+  configureFlags = [
+    "--enable-gui=${guiSupport}"
+    "--with-features=${features}"
+    "--disable-xsmp"              # XSMP session management
+    "--disable-xsmp_interact"     # XSMP interaction
+    "--disable-workshop"          # Sun Visual Workshop support
+    "--disable-sniff"             # Sniff interface
+    "--disable-hangulinput"       # Hangul input support
+    "--disable-fontset"           # X fontset output support
+    "--disable-acl"               # ACL support
+    "--disable-gpm"               # GPM (Linux mouse daemon)
+    "--disable-mzschemeinterp"
+    "--disable-gtk_check"
+    "--disable-gtk2_check"
+    "--disable-gnome_check"
+    "--disable-motif_check"
+    "--disable-athena_check"
+    "--disable-nextaf_check"
+    "--disable-carbon_check"
+    "--disable-gtktest"
+  ]
+  ++ stdenv.lib.optionals luaSupport [
+    "--with-lua-prefix=${args.lua}"
+    "--enable-luainterp"
+  ]
+  ++ stdenv.lib.optionals pythonSupport [
+    "--enable-python${if isPython3 then "3" else ""}"
+  ]
+  ++ stdenv.lib.optionals (pythonSupport && stdenv.isDarwin) [  # Why only for Darwin?
+    "--enable-python${if isPython3 then "3" else ""}interp=yes" # Duplicate?
+    "--with-python${if isPython3 then "3" else ""}-config-dir=${python}/lib"
+    "--disable-python${if isPython3 then "" else "3"}interp"
+  ]
+  ++ stdenv.lib.optional nlsSupport          "--enable-nls"
+  ++ stdenv.lib.optional perlSupport         "--enable-perlinterp"
+  ++ stdenv.lib.optional rubySupport         "--enable-rubyinterp"
+  ++ stdenv.lib.optional tclSupport          "--enable-tclinterp"
+  ++ stdenv.lib.optional multibyteSupport    "--enable-multibyte"
+  ++ stdenv.lib.optional cscopeSupport       "--enable-cscope"
+  ++ stdenv.lib.optional netbeansSupport     "--enable-netbeans"
+  ++ stdenv.lib.optional ximSupport          "--enable-xim";
+
+  nativeBuildInputs = [
+    pkgconfig
+  ]
+  ++ stdenv.lib.optional wrapPythonDrv makeWrapper
+  ++ stdenv.lib.optional nlsSupport gettext
+  ++ stdenv.lib.optional perlSupport perl
+  ;
+
+  buildInputs = [ ncurses libX11 libXext libSM libXpm libXt libXaw libXau
+    libXmu glib libICE ]
+    ++ (if guiSupport == "gtk3" then [gtk3] else [gtk2])
+    ++ stdenv.lib.optionals darwinSupport [ CoreServices CoreData Cocoa Foundation libobjc cf-private ]
+    ++ stdenv.lib.optional luaSupport lua
+    ++ stdenv.lib.optional pythonSupport python
+    ++ stdenv.lib.optional tclSupport tcl
+    ++ stdenv.lib.optional rubySupport ruby;
+
+  preConfigure = ''
+    '' + stdenv.lib.optionalString ftNixSupport ''
+      cp ${vimPlugins.vim-nix.src}/ftplugin/nix.vim runtime/ftplugin/nix.vim
+      cp ${vimPlugins.vim-nix.src}/indent/nix.vim runtime/indent/nix.vim
+      cp ${vimPlugins.vim-nix.src}/syntax/nix.vim runtime/syntax/nix.vim
+    '';
+
+  NIX_LDFLAGS = stdenv.lib.optionalString (darwinSupport && stdenv.isDarwin)
+    "/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation";
+
+  postInstall = ''
+  '' + stdenv.lib.optionalString stdenv.isLinux ''
     patchelf --set-rpath \
       "$(patchelf --print-rpath $out/bin/vim):${lib.makeLibraryPath buildInputs}" \
       "$out"/bin/{vim,gvim}
 
     ln -sfn '${nixosRuntimepath}' "$out"/share/vim/vimrc
+  '' + stdenv.lib.optionalString wrapPythonDrv ''
+    wrapProgram "$out/bin/vim" --prefix PATH : "${python}/bin"
+  '';
+
+  preInstall = ''
+    mkdir -p $out/share/applications $out/share/icons/{hicolor,locolor}/{16x16,32x32,48x48}/apps
   '';
 
   dontStrip = 1;
-})
+}
diff --git a/pkgs/applications/editors/vim/qvim.nix b/pkgs/applications/editors/vim/qvim.nix
index c23bf360daf3..81948918a114 100644
--- a/pkgs/applications/editors/vim/qvim.nix
+++ b/pkgs/applications/editors/vim/qvim.nix
@@ -1,110 +1,94 @@
 args@{ fetchgit, stdenv, ncurses, pkgconfig, gettext
-, composableDerivation, lib, config, python, perl, tcl, ruby, qt4
+, lib, config, python, perl, tcl, ruby, qt4
 , libX11, libXext, libSM, libXpm, libXt, libXaw, libXau, libXmu
-, libICE, ... }: with args;
+, libICE
+, lua
+, features
+, luaSupport       ? config.vim.lua or true
+, perlSupport      ? config.vim.perl or false      # Perl interpreter
+, pythonSupport    ? config.vim.python or true
+, rubySupport      ? config.vim.ruby or true
+, nlsSupport       ? config.vim.nls or false
+, tclSupport       ? config.vim.tcl or false
+, multibyteSupport ? config.vim.multibyte or false
+, cscopeSupport    ? config.vim.cscope or false
+, netbeansSupport  ? config.netbeans or true # eg envim is using it
+
+# by default, compile with darwin support if we're compiling on darwin, but
+# allow this to be disabled by setting config.vim.darwin to false
+, darwinSupport    ? stdenv.isDarwin && (config.vim.darwin or true)
+
+# add .nix filetype detection and minimal syntax highlighting support
+, ftNixSupport     ? config.vim.ftNix or true
+
+, ... }: with args;
 
 let tag = "20140827";
     sha256 = "0ncgbcm23z25naicxqkblz0mcl1zar2qwgi37y5ar8q8884w9ml2";
-in
+in {
 
-let inherit (args.composableDerivation) composableDerivation edf; in
-composableDerivation {
-} (fix: {
+  name = "qvim-7.4." + tag;
 
-    name = "qvim-7.4." + tag;
+  enableParallelBuilding = true; # test this
 
-    enableParallelBuilding = true; # test this
-
-    src = fetchgit {
-      url = https://bitbucket.org/equalsraf/vim-qt.git ;
-      rev = "refs/tags/package-" + tag;
-      inherit sha256;
-    };
-
-    # FIXME: adopt Darwin fixes from vim/default.nix, then chage meta.platforms.linux
-    # to meta.platforms.unix
-    preConfigure = assert (! stdenv.isDarwin); "";
-
-    configureFlags = [ "--with-vim-name=qvim" "--enable-gui=qt" "--with-features=${args.features}" ];
-
-    nativeBuildInputs
-      = [ ncurses pkgconfig libX11 libXext libSM libXpm libXt libXaw libXau
-          libXmu libICE qt4];
-
-    # most interpreters aren't tested yet.. (see python for example how to do it)
-    flags = {
-        ftNix = {
-          # because we cd to src in the main patch phase, we can't just add this
-          # patch to the list, we have to apply it manually
-          postPatch = ''
-            cd runtime
-            patch -p2 < ${./ft-nix-support.patch}
-            cd ..
-          '';
-        };
-      }
-      // edf { name = "darwin"; } #Disable Darwin (macOS) support.
-      // edf { name = "xsmp"; } #Disable XSMP session management
-      // edf { name = "xsmp_interact"; } #Disable XSMP interaction
-      // edf { name = "mzscheme"; } #Include MzScheme interpreter.
-      // edf { name = "perl"; feat = "perlinterp"; enable = { nativeBuildInputs = [perl]; };} #Include Perl interpreter.
-
-      // edf {
-        name = "python";
-        feat = "pythoninterp";
-        enable = {
-          nativeBuildInputs = [ python ];
-        } // lib.optionalAttrs stdenv.isDarwin {
-          configureFlags
-            = [ "--enable-pythoninterp=yes"
-                "--with-python-config-dir=${python}/lib" ];
-        };
-      }
-
-      // edf { name = "tcl"; enable = { nativeBuildInputs = [tcl]; }; } #Include Tcl interpreter.
-      // edf { name = "ruby"; feat = "rubyinterp"; enable = { nativeBuildInputs = [ruby]; };} #Include Ruby interpreter.
-      // edf {
-        name = "lua";
-        feat = "luainterp";
-        enable = {
-          nativeBuildInputs = [lua];
-          configureFlags = [
-            "--with-lua-prefix=${args.lua}"
-            "--enable-luainterp"
-          ];
-        };
-      }
-      // edf { name = "cscope"; } #Include cscope interface.
-      // edf { name = "workshop"; } #Include Sun Visual Workshop support.
-      // edf { name = "netbeans"; } #Disable NetBeans integration support.
-      // edf { name = "sniff"; feat = "sniff" ; } #Include Sniff interface.
-      // edf { name = "multibyte"; } #Include multibyte editing support.
-      // edf { name = "hangulinput"; feat = "hangulinput" ;} #Include Hangul input support.
-      // edf { name = "xim"; } #Include XIM input support.
-      // edf { name = "fontset"; } #Include X fontset output support.
-      // edf { name = "acl"; } #Don't check for ACL support.
-      // edf { name = "gpm"; } #Don't use gpm (Linux mouse daemon).
-      // edf { name = "nls"; enable = {nativeBuildInputs = [gettext];}; } #Don't support NLS (gettext()).
-      ;
-
-  cfg = {
-    luaSupport       = config.vim.lua or true;
-    pythonSupport    = config.vim.python or true;
-    rubySupport      = config.vim.ruby or true;
-    nlsSupport       = config.vim.nls or false;
-    tclSupport       = config.vim.tcl or false;
-    multibyteSupport = config.vim.multibyte or false;
-    cscopeSupport    = config.vim.cscope or false;
-    netbeansSupport  = config.netbeans or true; # eg envim is using it
-
-    # by default, compile with darwin support if we're compiling on darwin, but
-    # allow this to be disabled by setting config.vim.darwin to false
-    darwinSupport    = stdenv.isDarwin && (config.vim.darwin or true);
-
-    # add .nix filetype detection and minimal syntax highlighting support
-    ftNixSupport     = config.vim.ftNix or true;
+  src = fetchgit {
+    url = https://bitbucket.org/equalsraf/vim-qt.git;
+    rev = "refs/tags/package-" + tag;
+    inherit sha256;
   };
 
+  # FIXME: adopt Darwin fixes from vim/default.nix, then chage meta.platforms.linux
+  # to meta.platforms.unix
+  preConfigure = assert (! stdenv.isDarwin); "";
+
+  configureFlags = [
+    "--with-vim-name=qvim"
+    "--enable-gui=qt"
+    "--with-features=${features}"
+    "--disable-xsmp"
+    "--disable-xsmp_interact"
+    "--disable-workshop"          # Sun Visual Workshop support
+    "--disable-sniff"             # Sniff interface
+    "--disable-hangulinput"       # Hangul input support
+    "--disable-fontset"           # X fontset output support
+    "--disable-acl"               # ACL support
+    "--disable-gpm"               # GPM (Linux mouse daemon)
+    "--disable-mzscheme"
+  ]
+  ++ stdenv.lib.optionals luaSupport [
+    "--with-lua-prefix=${lua}"
+    "--enable-luainterp"
+  ]
+  ++ stdenv.lib.optional pythonSupport      "--enable-pythoninterp"
+  ++ stdenv.lib.optional (pythonSupport && stdenv.isDarwin) "--with-python-config-dir=${python}/lib"
+  ++ stdenv.lib.optional nlsSupport         "--enable-nls"
+  ++ stdenv.lib.optional perlSupport        "--enable-perlinterp"
+  ++ stdenv.lib.optional rubySupport        "--enable-rubyinterp"
+  ++ stdenv.lib.optional tclSupport         "--enable-tcl"
+  ++ stdenv.lib.optional multibyteSupport   "--enable-multibyte"
+  ++ stdenv.lib.optional darwinSupport      "--enable-darwin"
+  ++ stdenv.lib.optional cscopeSupport      "--enable-cscope";
+
+  nativeBuildInputs = [ ncurses pkgconfig libX11 libXext libSM libXpm libXt libXaw
+    libXau libXmu libICE qt4
+  ]
+  ++ stdenv.lib.optional nlsSupport gettext
+  ++ stdenv.lib.optional perlSupport perl
+  ++ stdenv.lib.optional pythonSupport python
+  ++ stdenv.lib.optional tclSupport tcl
+  ++ stdenv.lib.optional rubySupport ruby
+  ++ stdenv.lib.optional luaSupport lua
+  ;
+
+  postPatch = ''
+  '' + stdenv.lib.optionalString ftNixSupport ''
+    # because we cd to src in the main patch phase, we can't just add this
+    # patch to the list, we have to apply it manually
+    cd runtime
+    patch -p2 < ${./ft-nix-support.patch}
+    cd ..
+  '';
+
   postInstall = stdenv.lib.optionalString stdenv.isLinux ''
     rpath=`patchelf --print-rpath $out/bin/qvim`;
     for i in $nativeBuildInputs; do
@@ -125,5 +109,5 @@ composableDerivation {
     maintainers = with maintainers; [ smironov ttuegel ];
     platforms   = platforms.linux;
   };
-})
+}
 
diff --git a/pkgs/applications/networking/cluster/kubetail/default.nix b/pkgs/applications/networking/cluster/kubetail/default.nix
new file mode 100644
index 000000000000..201e3e8b30d2
--- /dev/null
+++ b/pkgs/applications/networking/cluster/kubetail/default.nix
@@ -0,0 +1,30 @@
+{ stdenv, fetchFromGitHub, lib, ... }:
+
+stdenv.mkDerivation rec {
+  name = "kubetail-${version}";
+  version = "1.6.1";
+
+  src = fetchFromGitHub {
+    owner = "johanhaleby";
+    repo = "kubetail";
+    rev = "${version}";
+    sha256 = "10ql1kdsmyrk73jb6f5saf2q38znm0vdihscj3c9n0qhyhk9blpl";
+  };
+
+  installPhase = ''
+    install -Dm755 kubetail $out/bin/kubetail
+  '';
+
+  meta = with lib; {
+    description = "Bash script to tail Kubernetes logs from multiple pods at the same time";
+    longDescription = ''
+      Bash script that enables you to aggregate (tail/follow) logs from
+      multiple pods into one stream. This is the same as running "kubectl logs
+      -f " but for multiple pods.
+    '';
+    homepage = https://github.com/johanhaleby/kubetail;
+    license = licenses.asl20;
+    maintainers = with maintainers; [ kalbasit ];
+    platforms = platforms.all;
+  };
+}
diff --git a/pkgs/build-support/build-maven.nix b/pkgs/build-support/build-maven.nix
index 30df3e8e7336..b9da06c43c82 100644
--- a/pkgs/build-support/build-maven.nix
+++ b/pkgs/build-support/build-maven.nix
@@ -16,10 +16,11 @@ infoFile: let
   script = writeText "build-maven-repository.sh" ''
     ${lib.concatStrings (map (dep: let
       inherit (dep)
-        url sha1 groupId artifactId version
-        authenticated metadata repository-id;
+        url sha1 groupId artifactId
+        version metadata repository-id;
 
       versionDir = dep.unresolved-version or version;
+      authenticated = dep.authenticated or false;
 
       fetch = (if authenticated then requireFile else fetchurl) {
         inherit url sha1;
diff --git a/pkgs/build-support/setup-hooks/remove-pytest-cache.sh b/pkgs/build-support/setup-hooks/remove-pytest-cache.sh
new file mode 100644
index 000000000000..7f3e08bfa67c
--- /dev/null
+++ b/pkgs/build-support/setup-hooks/remove-pytest-cache.sh
@@ -0,0 +1 @@
+postFixupHooks+=
diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix
index b1e2a3da3fd5..1ec0adafef8f 100644
--- a/pkgs/development/haskell-modules/configuration-common.nix
+++ b/pkgs/development/haskell-modules/configuration-common.nix
@@ -829,9 +829,6 @@ self: super: {
   # https://github.com/fizruk/http-api-data/issues/49
   http-api-data = dontCheck super.http-api-data;
 
-  # https://github.com/snoyberg/yaml/issues/106
-  yaml = disableCabalFlag super.yaml "system-libyaml";
-
   # https://github.com/diagrams/diagrams-lib/issues/288
   diagrams-lib = overrideCabal super.diagrams-lib (drv: { doCheck = !pkgs.stdenv.isi686; });
 
diff --git a/pkgs/development/haskell-modules/configuration-nix.nix b/pkgs/development/haskell-modules/configuration-nix.nix
index 3e4b18d86b92..a6cfef6f45f6 100644
--- a/pkgs/development/haskell-modules/configuration-nix.nix
+++ b/pkgs/development/haskell-modules/configuration-nix.nix
@@ -309,6 +309,9 @@ self: super: builtins.intersectAttrs super {
   # https://github.com/bos/pcap/issues/5
   pcap = addExtraLibrary super.pcap pkgs.libpcap;
 
+  # https://github.com/snoyberg/yaml/issues/106
+  yaml = disableCabalFlag super.yaml "system-libyaml";
+
   # The cabal files for these libraries do not list the required system dependencies.
   miniball = overrideCabal super.miniball (drv: {
     librarySystemDepends = [ pkgs.miniball ];
diff --git a/pkgs/development/interpreters/php/default.nix b/pkgs/development/interpreters/php/default.nix
index 6a7b994ee982..7c866911c593 100644
--- a/pkgs/development/interpreters/php/default.nix
+++ b/pkgs/development/interpreters/php/default.nix
@@ -1,21 +1,63 @@
 # pcre functionality is tested in nixos/tests/php-pcre.nix
-
-{ lib, stdenv, fetchurl, composableDerivation, flex, bison
-, mysql, libxml2, readline, zlib, curl, postgresql, gettext, html-tidy
+{ lib, stdenv, fetchurl, flex, bison
+, mysql, libxml2, readline, zlib, curl, postgresql, gettext
 , openssl, pcre, pkgconfig, sqlite, config, libjpeg, libpng, freetype
 , libxslt, libmcrypt, bzip2, icu, openldap, cyrus_sasl, libmhash, freetds
-, uwimap, pam, gmp, apacheHttpd, libiconv, systemd, libsodium }:
+, uwimap, pam, gmp, apacheHttpd, libiconv, systemd, libsodium, html-tidy
+}:
 
-let
+with lib;
 
+let
+  php7 = versionAtLeast version "7.0";
   generic =
-    { version, sha256 }:
-
-    let php7 = lib.versionAtLeast version "7.0";
-        mysqlndSupport = config.php.mysqlnd or false;
-        mysqlBuildInputs = lib.optional (!mysqlndSupport) mysql.connector-c;
-
-    in composableDerivation.composableDerivation {} (fixed: {
+  { version
+  , sha256
+  , imapSupport ? config.php.imap or (!stdenv.isDarwin)
+  , ldapSupport ? config.php.ldap or true
+  , mhashSupport ? config.php.mhash or true
+  , mysqlSupport ? (config.php.mysql or true) && (!php7)
+  , mysqlndSupport ? config.php.mysqlnd or false
+  , mysqliSupport ? config.php.mysqli or true
+  , pdo_mysqlSupport ? config.php.pdo_mysql or true
+  , libxml2Support ? config.php.libxml2 or true
+  , apxs2Support ? config.php.apxs2 or (!stdenv.isDarwin)
+  , embedSupport ? config.php.embed or false
+  , bcmathSupport ? config.php.bcmath or true
+  , socketsSupport ? config.php.sockets or true
+  , curlSupport ? config.php.curl or true
+  , curlWrappersSupport ? (config.php.curlWrappers or true) && (!php7)
+  , gettextSupport ? config.php.gettext or true
+  , pcntlSupport ? config.php.pcntl or true
+  , postgresqlSupport ? config.php.postgresql or true
+  , pdo_pgsqlSupport ? config.php.pdo_pgsql or true
+  , readlineSupport ? config.php.readline or true
+  , sqliteSupport ? config.php.sqlite or true
+  , soapSupport ? config.php.soap or true
+  , zlibSupport ? config.php.zlib or true
+  , opensslSupport ? config.php.openssl or true
+  , mbstringSupport ? config.php.mbstring or true
+  , gdSupport ? config.php.gd or true
+  , intlSupport ? config.php.intl or true
+  , exifSupport ? config.php.exif or true
+  , xslSupport ? config.php.xsl or false
+  , mcryptSupport ? config.php.mcrypt or true
+  , bz2Support ? config.php.bz2 or false
+  , zipSupport ? config.php.zip or true
+  , ftpSupport ? config.php.ftp or true
+  , fpmSupport ? config.php.fpm or true
+  , gmpSupport ? config.php.gmp or true
+  , mssqlSupport ? (config.php.mssql or (!stdenv.isDarwin)) && (!php7)
+  , ztsSupport ? config.php.zts or false
+  , calendarSupport ? config.php.calendar or true
+  , sodiumSupport ? (config.php.sodium or true) && (versionAtLeast version "7.2")
+  , tidySupport ? false
+  }:
+
+    let
+      mysqlBuildInputs = optional (!mysqlndSupport) mysql.connector-c;
+      libmcrypt' = libmcrypt.override { disablePosixThreads = true; };
+    in stdenv.mkDerivation {
 
       inherit version;
 
@@ -25,258 +67,99 @@ let
 
       nativeBuildInputs = [ pkgconfig ];
       buildInputs = [ flex bison pcre ]
-        ++ lib.optional stdenv.isLinux systemd;
-
-      CXXFLAGS = lib.optional stdenv.cc.isClang "-std=c++11";
-
-      flags = {
-
-        # much left to do here...
-
-        # SAPI modules:
-
-        apxs2 = {
-          configureFlags = ["--with-apxs2=${apacheHttpd.dev}/bin/apxs"];
-          buildInputs = [apacheHttpd];
-        };
-
-        embed = {
-          configureFlags = ["--enable-embed"];
-        };
-
-        # Extensions
-        imap = {
-          configureFlags = [
-            "--with-imap=${uwimap}"
-            "--with-imap-ssl"
-            ];
-          buildInputs = [ uwimap openssl pam ];
-        };
-
-        ldap = {
-          configureFlags = [
-            "--with-ldap=/invalid/path"
-            "LDAP_DIR=${openldap.dev}"
-            "LDAP_INCDIR=${openldap.dev}/include"
-            "LDAP_LIBDIR=${openldap.out}/lib"
-            (lib.optional stdenv.isLinux "--with-ldap-sasl=${cyrus_sasl.dev}")
-            ];
-          buildInputs = [openldap openssl] ++ lib.optional stdenv.isLinux cyrus_sasl;
-        };
-
-        mhash = {
-          configureFlags = ["--with-mhash"];
-          buildInputs = [libmhash];
-        };
-
-        curl = {
-          configureFlags = ["--with-curl=${curl.dev}"];
-          buildInputs = [curl openssl];
-        };
-
-        curlWrappers = {
-          configureFlags = ["--with-curlwrappers"];
-        };
-
-        zlib = {
-          configureFlags = ["--with-zlib=${zlib.dev}"];
-          buildInputs = [zlib];
-        };
-
-        libxml2 = {
-          configureFlags = [
-            "--with-libxml-dir=${libxml2.dev}"
-            ];
-          buildInputs = [ libxml2 ];
-        };
-
-        pcntl = {
-          configureFlags = [ "--enable-pcntl" ];
-        };
-
-        readline = {
-          configureFlags = ["--with-readline=${readline.dev}"];
-          buildInputs = [ readline ];
-        };
-
-        sqlite = {
-          configureFlags = ["--with-pdo-sqlite=${sqlite.dev}"];
-          buildInputs = [ sqlite ];
-        };
-
-        postgresql = {
-          configureFlags = ["--with-pgsql=${postgresql}"];
-          buildInputs = [ postgresql ];
-        };
-
-        pdo_pgsql = {
-          configureFlags = ["--with-pdo-pgsql=${postgresql}"];
-          buildInputs = [ postgresql ];
-        };
-
-        mysql = {
-          configureFlags = ["--with-mysql${if mysqlndSupport then "=mysqlnd" else ""}"];
-          buildInputs = mysqlBuildInputs;
-        };
-
-        mysqli = {
-          configureFlags = ["--with-mysqli=${if mysqlndSupport then "mysqlnd" else "${mysql.connector-c}/bin/mysql_config"}"];
-          buildInputs = mysqlBuildInputs;
-        };
-
-        mysqli_embedded = {
-          configureFlags = ["--enable-embedded-mysqli"];
-          depends = "mysqli";
-          assertion = fixed.mysqliSupport;
-        };
-
-        pdo_mysql = {
-          configureFlags = ["--with-pdo-mysql=${if mysqlndSupport then "mysqlnd" else mysql.connector-c}"];
-          buildInputs = mysqlBuildInputs;
-        };
-
-        bcmath = {
-          configureFlags = ["--enable-bcmath"];
-        };
+        ++ optional stdenv.isLinux systemd
+        ++ optionals imapSupport [ uwimap openssl pam ]
+        ++ optionals curlSupport [ curl openssl ]
+        ++ optionals ldapSupport [ openldap openssl ]
+        ++ optionals gdSupport [ libpng libjpeg freetype ]
+        ++ optionals opensslSupport [ openssl openssl.dev ]
+        ++ optional apxs2Support apacheHttpd
+        ++ optional (ldapSupport && stdenv.isLinux) cyrus_sasl
+        ++ optional mhashSupport libmhash
+        ++ optional zlibSupport zlib
+        ++ optional libxml2Support libxml2
+        ++ optional readlineSupport readline
+        ++ optional sqliteSupport sqlite
+        ++ optional postgresqlSupport postgresql
+        ++ optional pdo_pgsqlSupport postgresql
+        ++ optional pdo_mysqlSupport mysqlBuildInputs
+        ++ optional mysqlSupport mysqlBuildInputs
+        ++ optional mysqliSupport mysqlBuildInputs
+        ++ optional gmpSupport gmp
+        ++ optional gettextSupport gettext
+        ++ optional intlSupport icu
+        ++ optional xslSupport libxslt
+        ++ optional mcryptSupport libmcrypt'
+        ++ optional bz2Support bzip2
+        ++ optional (mssqlSupport && !stdenv.isDarwin) freetds
+        ++ optional sodiumSupport libsodium
+        ++ optional tidySupport html-tidy;
+
+      CXXFLAGS = optional stdenv.cc.isClang "-std=c++11";
 
-        gd = {
-          # FIXME: Our own gd package doesn't work, see https://bugs.php.net/bug.php?id=60108.
-          configureFlags = [
-            "--with-gd"
-            "--with-freetype-dir=${freetype.dev}"
-            "--with-png-dir=${libpng.dev}"
-            "--with-jpeg-dir=${libjpeg.dev}"
-          ];
-          buildInputs = [ libpng libjpeg freetype ];
-        };
 
-        gmp = {
-          configureFlags = ["--with-gmp=${gmp.dev}"];
-          buildInputs = [ gmp ];
-        };
-
-        soap = {
-          configureFlags = ["--enable-soap"];
-        };
-
-        sockets = {
-          configureFlags = ["--enable-sockets"];
-        };
-
-        openssl = {
-          configureFlags = ["--with-openssl"];
-          buildInputs = [openssl openssl.dev];
-        };
-
-        mbstring = {
-          configureFlags = ["--enable-mbstring"];
-        };
-
-        gettext = {
-          configureFlags = ["--with-gettext=${gettext}"];
-          buildInputs = [gettext];
-        };
-
-        intl = {
-          configureFlags = ["--enable-intl"];
-          buildInputs = [icu];
-        };
-
-        exif = {
-          configureFlags = ["--enable-exif"];
-        };
-
-        xsl = {
-          configureFlags = ["--with-xsl=${libxslt.dev}"];
-          buildInputs = [libxslt];
-        };
-
-        mcrypt = let libmcrypt' = libmcrypt.override { disablePosixThreads = true; }; in {
-          configureFlags = ["--with-mcrypt=${libmcrypt'}"];
-          buildInputs = [libmcrypt'];
-        };
-
-        bz2 = {
-          configureFlags = ["--with-bz2=${bzip2.dev}"];
-          buildInputs = [bzip2];
-        };
-
-        zip = {
-          configureFlags = ["--enable-zip"];
-        };
-
-        ftp = {
-          configureFlags = ["--enable-ftp"];
-        };
-
-        fpm = {
-          configureFlags = ["--enable-fpm"];
-        };
-
-        mssql = stdenv.lib.optionalAttrs (!stdenv.isDarwin) {
-          configureFlags = ["--with-mssql=${freetds}"];
-          buildInputs = [freetds];
-        };
-
-        zts = {
-          configureFlags = ["--enable-maintainer-zts"];
-        };
-
-        calendar = {
-          configureFlags = ["--enable-calendar"];
-        };
-
-        sodium = {
-          configureFlags = ["--with-sodium=${libsodium.dev}"];
-          buildInputs = [libsodium];
-        };
-
-        tidy = {
-          configureFlags = [ "--with-tidy=${html-tidy}" ];
-          buildInputs = [ html-tidy ];
-        };
-      };
+      configureFlags = [
+        "--with-config-file-scan-dir=/etc/php.d"
+        "--with-pcre-regex=${pcre.dev} PCRE_LIBDIR=${pcre}"
+      ]
+      ++ optional stdenv.isDarwin "--with-iconv=${libiconv}"
+      ++ optional stdenv.isLinux  "--with-fpm-systemd"
+      ++ optionals imapSupport [
+        "--with-imap=${uwimap}"
+        "--with-imap-ssl"
+      ]
+      ++ optionals ldapSupport [
+        "--with-ldap=/invalid/path"
+        "LDAP_DIR=${openldap.dev}"
+        "LDAP_INCDIR=${openldap.dev}/include"
+        "LDAP_LIBDIR=${openldap.out}/lib"
+      ]
+      ++ optional (ldapSupport && stdenv.isLinux)   "--with-ldap-sasl=${cyrus_sasl.dev}"
+      ++ optional apxs2Support "--with-apxs2=${apacheHttpd.dev}/bin/apxs"
+      ++ optional embedSupport "--enable-embed"
+      ++ optional mhashSupport "--with-mhash"
+      ++ optional curlSupport "--with-curl=${curl.dev}"
+      ++ optional curlWrappersSupport "--with-curlwrappers"
+      ++ optional zlibSupport "--with-zlib=${zlib.dev}"
+      ++ optional libxml2Support "--with-libxml-dir=${libxml2.dev}"
+      ++ optional pcntlSupport "--enable-pcntl"
+      ++ optional readlineSupport "--with-readline=${readline.dev}"
+      ++ optional sqliteSupport "--with-pdo-sqlite=${sqlite.dev}"
+      ++ optional postgresqlSupport "--with-pgsql=${postgresql}"
+      ++ optional pdo_pgsqlSupport "--with-pdo-pgsql=${postgresql}"
+      ++ optional pdo_mysqlSupport "--with-pdo-mysql=${if mysqlndSupport then "mysqlnd" else mysql.connector-c}"
+      ++ optional mysqlSupport "--with-mysql${if mysqlndSupport then "=mysqlnd" else ""}"
+      ++ optionals mysqliSupport [
+        "--with-mysqli=${if mysqlndSupport then "mysqlnd" else "${mysql.connector-c}/bin/mysql_config"}"
+      ]
+      ++ optional bcmathSupport "--enable-bcmath"
+      # FIXME: Our own gd package doesn't work, see https://bugs.php.net/bug.php?id=60108.
+      ++ optionals gdSupport [
+        "--with-gd"
+        "--with-freetype-dir=${freetype.dev}"
+        "--with-png-dir=${libpng.dev}"
+        "--with-jpeg-dir=${libjpeg.dev}"
+      ]
+      ++ optional gmpSupport "--with-gmp=${gmp.dev}"
+      ++ optional soapSupport "--enable-soap"
+      ++ optional socketsSupport "--enable-sockets"
+      ++ optional opensslSupport "--with-openssl"
+      ++ optional mbstringSupport "--enable-mbstring"
+      ++ optional gettextSupport "--with-gettext=${gettext}"
+      ++ optional intlSupport "--enable-intl"
+      ++ optional exifSupport "--enable-exif"
+      ++ optional xslSupport "--with-xsl=${libxslt.dev}"
+      ++ optional mcryptSupport "--with-mcrypt=${libmcrypt'}"
+      ++ optional bz2Support "--with-bz2=${bzip2.dev}"
+      ++ optional zipSupport "--enable-zip"
+      ++ optional ftpSupport "--enable-ftp"
+      ++ optional fpmSupport "--enable-fpm"
+      ++ optional (mssqlSupport && !stdenv.isDarwin) "--with-mssql=${freetds}"
+      ++ optional ztsSupport "--enable-maintainer-zts"
+      ++ optional calendarSupport "--enable-calendar"
+      ++ optional sodiumSupport "--with-sodium=${libsodium.dev}"
+      ++ optional tidySupport "--with-tidy=${html-tidy}";
 
-      cfg = {
-        imapSupport = config.php.imap or (!stdenv.isDarwin);
-        ldapSupport = config.php.ldap or true;
-        mhashSupport = config.php.mhash or true;
-        mysqlSupport = (!php7) && (config.php.mysql or true);
-        mysqliSupport = config.php.mysqli or true;
-        pdo_mysqlSupport = config.php.pdo_mysql or true;
-        libxml2Support = config.php.libxml2 or true;
-        apxs2Support = config.php.apxs2 or (!stdenv.isDarwin);
-        embedSupport = config.php.embed or false;
-        bcmathSupport = config.php.bcmath or true;
-        socketsSupport = config.php.sockets or true;
-        curlSupport = config.php.curl or true;
-        curlWrappersSupport = (!php7) && (config.php.curlWrappers or true);
-        gettextSupport = config.php.gettext or true;
-        pcntlSupport = config.php.pcntl or true;
-        postgresqlSupport = config.php.postgresql or true;
-        pdo_pgsqlSupport = config.php.pdo_pgsql or true;
-        readlineSupport = config.php.readline or true;
-        sqliteSupport = config.php.sqlite or true;
-        soapSupport = config.php.soap or true;
-        zlibSupport = config.php.zlib or true;
-        opensslSupport = config.php.openssl or true;
-        mbstringSupport = config.php.mbstring or true;
-        gdSupport = config.php.gd or true;
-        intlSupport = config.php.intl or true;
-        exifSupport = config.php.exif or true;
-        xslSupport = config.php.xsl or false;
-        mcryptSupport = config.php.mcrypt or true;
-        bz2Support = config.php.bz2 or false;
-        zipSupport = config.php.zip or true;
-        ftpSupport = config.php.ftp or true;
-        fpmSupport = config.php.fpm or true;
-        gmpSupport = config.php.gmp or true;
-        mssqlSupport = (!php7) && (config.php.mssql or (!stdenv.isDarwin));
-        ztsSupport = config.php.zts or false;
-        calendarSupport = config.php.calendar or true;
-        sodiumSupport = (lib.versionAtLeast version "7.2") && config.php.sodium or true;
-        tidySupport = php7 && config.php.tidy or true;
-      };
 
       hardeningDisable = [ "bindnow" ];
 
@@ -298,12 +181,6 @@ let
           --includedir=$dev/include)
       '';
 
-      configureFlags = [
-        "--with-config-file-scan-dir=/etc/php.d"
-        "--with-pcre-regex=${pcre.dev} PCRE_LIBDIR=${pcre}"
-      ] ++ lib.optional stdenv.isDarwin "--with-iconv=${libiconv}"
-        ++ lib.optional stdenv.isLinux  "--with-fpm-systemd";
-
       postInstall = ''
         cp php.ini-production $out/etc/php.ini
       '';
@@ -332,7 +209,7 @@ let
 
       patches = if !php7 then [ ./fix-paths.patch ] else [ ./fix-paths-php7.patch ];
 
-      postPatch = lib.optional stdenv.isDarwin ''
+      postPatch = optional stdenv.isDarwin ''
         substituteInPlace configure --replace "-lstdc++" "-lc++"
       '';
 
@@ -340,7 +217,7 @@ let
 
       outputs = [ "out" "dev" ];
 
-    });
+    };
 
 in {
   php56 = generic {
diff --git a/pkgs/development/libraries/libfilezilla/default.nix b/pkgs/development/libraries/libfilezilla/default.nix
index a86cf9b935ce..367f1c9aadd3 100644
--- a/pkgs/development/libraries/libfilezilla/default.nix
+++ b/pkgs/development/libraries/libfilezilla/default.nix
@@ -2,11 +2,11 @@
 
 stdenv.mkDerivation rec {
   name = "libfilezilla-${version}";
-  version = "0.12.3";
+  version = "0.13.0";
 
   src = fetchurl {
     url = "http://download.filezilla-project.org/libfilezilla/${name}.tar.bz2";
-    sha256 = "1v606kcz2rdmmlwxrv3xvwh7ia1nh6jfc9bhjw2r4ai3rm16gch5";
+    sha256 = "0sk8kz2zrvf7kp9jrp3l4rpipv4xh0hg8d4h734xyag7vd03rjpz";
   };
 
   meta = with stdenv.lib; {
diff --git a/pkgs/development/libraries/pcl/default.nix b/pkgs/development/libraries/pcl/default.nix
index 59f674789e47..9fb2e0b7fedb 100644
--- a/pkgs/development/libraries/pcl/default.nix
+++ b/pkgs/development/libraries/pcl/default.nix
@@ -1,4 +1,5 @@
-{ stdenv, fetchFromGitHub, cmake, qhull, flann, boost, vtk, eigen, pkgconfig, qtbase
+{ stdenv, fetchFromGitHub, fetchpatch, cmake
+, qhull, flann, boost, vtk, eigen, pkgconfig, qtbase
 , libusb1, libpcap, libXt, libpng, Cocoa, AGL, cf-private, OpenGL
 }:
 
@@ -12,6 +13,14 @@ stdenv.mkDerivation rec {
     sha256 = "05wvqqi2fyk5innw4mg356r71c1hmc9alc7xkf4g81ds3b3867xq";
   };
 
+  patches = [
+    # boost-1.67 compatibility
+    (fetchpatch {
+      url = "https://github.com/PointCloudLibrary/pcl/commit/2309bdab20fb2a385d374db6a87349199279db18.patch";
+      sha256 = "112p4687xrm0vsm0magmkvsm1hpks9hj42fm0lncy3yy2j1v3r4h";
+      name = "boost167-random.patch";
+  })];
+
   enableParallelBuilding = true;
 
   nativeBuildInputs = [ pkgconfig cmake ];
diff --git a/pkgs/development/python-modules/pyserial/default.nix b/pkgs/development/python-modules/pyserial/default.nix
index 508104d33129..c7787a42691b 100644
--- a/pkgs/development/python-modules/pyserial/default.nix
+++ b/pkgs/development/python-modules/pyserial/default.nix
@@ -10,7 +10,7 @@ buildPythonPackage rec {
   };
 
   checkPhase = "python -m unittest discover -s test";
-  doInstallCheck = !hostPlatform.isDarwin; # broken on darwin
+  doCheck = !hostPlatform.isDarwin; # broken on darwin
 
   meta = with lib; {
     homepage = "https://github.com/pyserial/pyserial";
diff --git a/pkgs/development/python-modules/wxPython/4.0.nix b/pkgs/development/python-modules/wxPython/4.0.nix
new file mode 100644
index 000000000000..39e3d7fb3fa1
--- /dev/null
+++ b/pkgs/development/python-modules/wxPython/4.0.nix
@@ -0,0 +1,41 @@
+{ lib
+, buildPythonPackage
+, fetchPypi
+, pkgconfig
+, gtk3
+, libjpeg
+, libtiff
+, SDL
+, gst-plugins-base
+, libnotify
+, freeglut
+, xorg
+, which
+}:
+
+buildPythonPackage rec {
+  pname = "wxPython";
+  version = "4.0.3";
+
+  src = fetchPypi {
+    inherit pname version;
+    sha256 = "8d0dfc0146c24749ce00d575e35cc2826372e809d5bc4a57bde6c89031b59e75";
+  };
+
+  nativeBuildInputs = [
+    pkgconfig
+  ];
+
+  buildInputs = [
+    gtk3 libjpeg libtiff SDL gst-plugins-base libnotify freeglut xorg.libSM
+    which
+  ];
+
+
+  meta = {
+    description = "Cross platform GUI toolkit for Python, Phoenix version";
+    homepage = http://wxpython.org/;
+    license = lib.licenses.wxWindows;
+  };
+
+}
\ No newline at end of file
diff --git a/pkgs/development/tools/dep/default.nix b/pkgs/development/tools/dep/default.nix
index 0d4f72fad80a..283193a485cd 100644
--- a/pkgs/development/tools/dep/default.nix
+++ b/pkgs/development/tools/dep/default.nix
@@ -2,7 +2,7 @@
 
 buildGoPackage rec {
   name = "dep-${version}";
-  version = "0.4.1";
+  version = "0.5.0";
   rev = "v${version}";
 
   goPackagePath = "github.com/golang/dep";
@@ -12,7 +12,7 @@ buildGoPackage rec {
     inherit rev;
     owner = "golang";
     repo = "dep";
-    sha256 = "0183xq5l4sinnclynv6xi85vmk69mqpy5wjfsgh8bxwziq3vkd7y";
+    sha256 = "1p35995w2f8rp4cxhcwnhdv26ajx6gxx9pm2ijb5sjy2pwhw5c6j";
   };
 
   buildFlagsArray = ("-ldflags=-s -w -X main.commitHash=${rev} -X main.version=${version}");
@@ -22,6 +22,6 @@ buildGoPackage rec {
     description = "Go dependency management tool";
     license = licenses.bsd3;
     platforms = platforms.all;
-    maintainers = [ maintainers.carlsverre ];
+    maintainers = with maintainers; [ carlsverre rvolosatovs ];
   };
 }
diff --git a/pkgs/development/tools/kustomize/default.nix b/pkgs/development/tools/kustomize/default.nix
new file mode 100644
index 000000000000..4f9512b22137
--- /dev/null
+++ b/pkgs/development/tools/kustomize/default.nix
@@ -0,0 +1,28 @@
+# This file was generated by https://github.com/kamilchm/go2nix v1.2.1
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
+
+buildGoPackage rec {
+  name = "kustomize-${version}";
+  version = "1.0.4";
+
+  goPackagePath = "github.com/kubernetes-sigs/kustomize";
+
+  src = fetchFromGitHub {
+    sha256 = "0lbf94wz34axaf8ps7h79qbj4dpihrpvnqa12zrawcmmgqallwhm";
+    rev = "v${version}";
+    repo = "kustomize";
+    owner = "kubernetes-sigs";
+  };
+
+  meta = with lib; {
+    description = "Customization of kubernetes YAML configurations";
+    longDescription = ''
+      kustomize lets you customize raw, template-free YAML files for
+      multiple purposes, leaving the original YAML untouched and usable
+      as is.
+    '';
+    homepage = https://github.com/kubernetes-sigs/kustomize;
+    license = licenses.asl20;
+    maintainers = [ maintainers.carlosdagos ];
+  };
+}
diff --git a/pkgs/development/tools/misc/ycmd/default.nix b/pkgs/development/tools/misc/ycmd/default.nix
index 2eb9b453661b..c0e12aa22c44 100644
--- a/pkgs/development/tools/misc/ycmd/default.nix
+++ b/pkgs/development/tools/misc/ycmd/default.nix
@@ -7,12 +7,12 @@
 
 stdenv.mkDerivation rec {
   name = "ycmd-${version}";
-  version = "2018-06-14";
+  version = "2018-07-24";
 
   src = fetchgit {
     url = "https://github.com/Valloric/ycmd.git";
-    rev = "29e36f74f749d10b8d6ce285c1453fac26f15a41";
-    sha256 = "0s62nf18jmgjihyba7lk7si8xrxsg60whdr430nlb5gjikag8zr5";
+    rev = "f8a8b04892b925efeee24298a957cc6d6a69ad06";
+    sha256 = "1br2sh6bs0fg1axq2hq9f48fz8klkzydi1mf0j0jdsh3zjzkmxbn";
   };
 
   nativeBuildInputs = [ cmake ];
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
 
     mkdir -p $out/lib/ycmd/third_party/{gocode,godef,racerd/target/release}
 
-    for p in jedi waitress frozendict bottle python-future requests; do
+    for p in jedi waitress frozendict bottle parso python-future requests; do
       cp -r third_party/$p $out/lib/ycmd/third_party
     done
 
diff --git a/pkgs/misc/vim-plugins/default.nix b/pkgs/misc/vim-plugins/default.nix
index b52e63241990..8a9580d99e17 100644
--- a/pkgs/misc/vim-plugins/default.nix
+++ b/pkgs/misc/vim-plugins/default.nix
@@ -2848,11 +2848,11 @@ let
   };
 
   youcompleteme = buildVimPluginFrom2Nix { # created by nix#NixDerivation
-    name = "youcompleteme-2018-06-20";
+    name = "youcompleteme-2018-07-24";
     src = fetchgit {
       url = "https://github.com/valloric/youcompleteme";
-      rev = "e1ead995c13fe20989ee3d69fd76b20c5fff5d5b";
-      sha256 = "01my9m7a5m24zrh6i867fhqz42jxs0ai2pl4pra8wzvyk4ai1p5f";
+      rev = "459b3e620e45191b15c48c66b02ff89f1a0674db";
+      sha256 = "0s4sndx0mm13xcb559agfcqqdwhp2sr7kpp4ksc9gx41k7626rdr";
     };
     dependencies = [];
     buildPhase = ''
@@ -3259,7 +3259,7 @@ let
       sha256 = "0hj5bhfhd9am11ixaxad370p982bjig53mbm74fi6slhjpikdrdq";
     };
     dependencies = [];
-    buildInputs = [ python3 ]; 
+    buildInputs = [ python3 ];
     buildPhase = ''
       pushd ./rplugin/python3/deoplete/ujson
       python3 setup.py build --build-base=$PWD/build --build-lib=$PWD/build
diff --git a/pkgs/os-specific/darwin/skhd/default.nix b/pkgs/os-specific/darwin/skhd/default.nix
index c51ada10d688..b3bf590bf268 100644
--- a/pkgs/os-specific/darwin/skhd/default.nix
+++ b/pkgs/os-specific/darwin/skhd/default.nix
@@ -2,13 +2,13 @@
 
 stdenv.mkDerivation rec {
   name = "skhd-${version}";
-  version = "0.1.1";
+  version = "0.2.2";
 
   src = fetchFromGitHub {
     owner = "koekeishiya";
     repo = "skhd";
     rev = "v${version}";
-    sha256 = "1wh7v90ydh27gbaiwn2r6ncx6yiic4mph3w9vi1282nz2q02zxss";
+    sha256 = "0mn6svz2mqbpwlx510r447vflfcxryykpin6h6429dlz0wjlipa8";
   };
 
   buildInputs = [ Carbon ];
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     description = "Simple hotkey daemon for macOS";
     homepage = https://github.com/koekeishiya/skhd;
     platforms = platforms.darwin;
-    maintainers = with maintainers; [ lnl7 ];
+    maintainers = with maintainers; [ lnl7 periklis ];
     license = licenses.mit;
   };
 }
diff --git a/pkgs/os-specific/linux/fuse/default.nix b/pkgs/os-specific/linux/fuse/default.nix
index 594f966c2f42..644841131674 100644
--- a/pkgs/os-specific/linux/fuse/default.nix
+++ b/pkgs/os-specific/linux/fuse/default.nix
@@ -6,12 +6,12 @@ let
   };
 in {
   fuse_2 = mkFuse {
-    version = "2.9.7";
-    sha256Hash = "1wyjjfb7p4jrkk15zryzv33096a5fmsdyr2p4b00dd819wnly2n2";
+    version = "2.9.8";
+    sha256Hash = "0s04ln4k9zvvbjih8ybaa19fxg8xv7dcsz2yrlbk35psnf3l67af";
   };
 
   fuse_3 = mkFuse {
-    version = "3.2.4";
-    sha256Hash = "1ybgd4s7naiyvaris7j6fzp604cgi5mgrn715x8l4kn5k9d840im";
+    version = "3.2.5";
+    sha256Hash = "0ibf2isbkm8p1gfaqpqblwsg0lm4s1rmcipv1qcg0wc4wwsbnqpx";
   };
 }
diff --git a/pkgs/os-specific/linux/kernel/linux-4.14.nix b/pkgs/os-specific/linux/kernel/linux-4.14.nix
index 4a364a824d9f..2bff43c93dee 100644
--- a/pkgs/os-specific/linux/kernel/linux-4.14.nix
+++ b/pkgs/os-specific/linux/kernel/linux-4.14.nix
@@ -3,7 +3,7 @@
 with stdenv.lib;
 
 buildLinux (args // rec {
-  version = "4.14.57";
+  version = "4.14.58";
 
   # modDirVersion needs to be x.y.z, will automatically add .0 if needed
   modDirVersion = if (modDirVersionArg == null) then concatStrings (intersperse "." (take 3 (splitString "." "${version}.0"))) else modDirVersionArg;
@@ -13,6 +13,6 @@ buildLinux (args // rec {
 
   src = fetchurl {
     url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
-    sha256 = "046qvgf44sn51g979whzvc6qrbz31gwxwm9xkka93vmqavr415aa";
+    sha256 = "1zfyrcfsx9410gnjk1hrjs5d4p93qm6k2r9q24i5c1nhfhzf0rgz";
   };
 } // (args.argsOverride or {}))
diff --git a/pkgs/os-specific/linux/kernel/linux-4.17.nix b/pkgs/os-specific/linux/kernel/linux-4.17.nix
index 9de96398e3e6..2ac619232d4c 100644
--- a/pkgs/os-specific/linux/kernel/linux-4.17.nix
+++ b/pkgs/os-specific/linux/kernel/linux-4.17.nix
@@ -3,7 +3,7 @@
 with stdenv.lib;
 
 buildLinux (args // rec {
-  version = "4.17.9";
+  version = "4.17.10";
 
   # modDirVersion needs to be x.y.z, will automatically add .0 if needed
   modDirVersion = if (modDirVersionArg == null) then concatStrings (intersperse "." (take 3 (splitString "." "${version}.0"))) else modDirVersionArg;
@@ -13,6 +13,6 @@ buildLinux (args // rec {
 
   src = fetchurl {
     url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
-    sha256 = "1frsg1qli4922w172mx96n0l7yzhiw6kirzzw4svsq3qsfnxq57x";
+    sha256 = "1s0vzzdcixy2m3ybd9z1h5b2wiiz2mgnwn09jxvj1v4rwjix457a";
   };
 } // (args.argsOverride or {}))
diff --git a/pkgs/os-specific/linux/kernel/linux-4.4.nix b/pkgs/os-specific/linux/kernel/linux-4.4.nix
index f654853eca42..d4a2c56a8943 100644
--- a/pkgs/os-specific/linux/kernel/linux-4.4.nix
+++ b/pkgs/os-specific/linux/kernel/linux-4.4.nix
@@ -1,11 +1,11 @@
 { stdenv, buildPackages, hostPlatform, fetchurl, perl, buildLinux, ... } @ args:
 
 buildLinux (args // rec {
-  version = "4.4.143";
+  version = "4.4.144";
   extraMeta.branch = "4.4";
 
   src = fetchurl {
     url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
-    sha256 = "0n737jdk9ms7v7zkhf45nfdg2jcyap4qpzxm162f4q9zz3sh0dif";
+    sha256 = "11lsf62qd9qm6n6ilxwx0zag3phvfmfjpbdc24j4p2c9gfgqpyss";
   };
 } // (args.argsOverride or {}))
diff --git a/pkgs/os-specific/linux/kernel/linux-4.9.nix b/pkgs/os-specific/linux/kernel/linux-4.9.nix
index aff61de93be7..3fe55b2a6f38 100644
--- a/pkgs/os-specific/linux/kernel/linux-4.9.nix
+++ b/pkgs/os-specific/linux/kernel/linux-4.9.nix
@@ -1,11 +1,11 @@
 { stdenv, buildPackages, hostPlatform, fetchurl, perl, buildLinux, ... } @ args:
 
 buildLinux (args // rec {
-  version = "4.9.114";
+  version = "4.9.115";
   extraMeta.branch = "4.9";
 
   src = fetchurl {
     url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
-    sha256 = "1c3j82rcnj03bk5s2i11mhksv5l09hmkfs3rpbj5msnrn123ds76";
+    sha256 = "0fddhw9v5l8k2j31zlfikd2g397ngyynfbwg92z17vp510fxjf20";
   };
 } // (args.argsOverride or {}))
diff --git a/pkgs/servers/monitoring/grafana/default.nix b/pkgs/servers/monitoring/grafana/default.nix
index 217ac3f6d914..4385a4e020c2 100644
--- a/pkgs/servers/monitoring/grafana/default.nix
+++ b/pkgs/servers/monitoring/grafana/default.nix
@@ -1,7 +1,7 @@
 { lib, buildGoPackage, fetchurl, fetchFromGitHub, phantomjs2 }:
 
 buildGoPackage rec {
-  version = "5.2.1";
+  version = "5.2.2";
   name = "grafana-${version}";
   goPackagePath = "github.com/grafana/grafana";
 
@@ -9,12 +9,12 @@ buildGoPackage rec {
     rev = "v${version}";
     owner = "grafana";
     repo = "grafana";
-    sha256 = "0gv7g6ddcmdkjd1xp9dg2kq7askzaw1vkmcii21glqb74k2jfg74";
+    sha256 = "17w8ljq4p1sxcdpsiz4221gwhi3ykggpisnx1wdw22g2160q9sdj";
   };
 
   srcStatic = fetchurl {
     url = "https://s3-us-west-2.amazonaws.com/grafana-releases/release/grafana-${version}.linux-amd64.tar.gz";
-    sha256 = "0j69a9cjvkknq19aa2l634b48zy1lwmv2p676hzc856zgq3h6m9m";
+    sha256 = "1frbk13sww3sw09mpkijii1kf7m19hqg58ps8gvs4dvxg12bbv3l";
   };
 
   postPatch = ''
diff --git a/pkgs/stdenv/cross/default.nix b/pkgs/stdenv/cross/default.nix
index 29521874d1eb..bc8d772530a1 100644
--- a/pkgs/stdenv/cross/default.nix
+++ b/pkgs/stdenv/cross/default.nix
@@ -43,6 +43,7 @@ in lib.init bootStages ++ [
       # a different platform, and so are disabled.
       overrides = _: _: {};
       extraBuildInputs = [ ]; # Old ones run on wrong platform
+      allowedRequisites = null;
 
       cc = if crossSystem.useiOSPrebuilt or false
              then buildPackages.darwin.iosSdkPkgs.clang
diff --git a/pkgs/tools/admin/azure-cli/default.nix b/pkgs/tools/admin/azure-cli/default.nix
deleted file mode 100644
index e69de29bb2d1..000000000000
--- a/pkgs/tools/admin/azure-cli/default.nix
+++ /dev/null
diff --git a/pkgs/tools/filesystems/simg2img/default.nix b/pkgs/tools/filesystems/simg2img/default.nix
new file mode 100644
index 000000000000..94c45ec4689a
--- /dev/null
+++ b/pkgs/tools/filesystems/simg2img/default.nix
@@ -0,0 +1,25 @@
+{ stdenv, fetchFromGitHub, zlib }:
+
+stdenv.mkDerivation rec {
+  name = "simg2img-${version}";
+  version = "1.1.3";
+
+  src = fetchFromGitHub {
+    owner = "anestisb";
+    repo = "android-simg2img";
+    rev = "${version}";
+    sha256 = "119gl9i61g2wr07hzv6mi1ihql6yd6pwq94ki2pgcpfbamv8f6si";
+  };
+
+  buildInputs = [ zlib ];
+
+  makeFlags = [ "PREFIX=$(out)" ];
+
+  meta = with stdenv.lib; {
+    description = "Tool to convert Android sparse images to raw images";
+    homepage = "https://github.com/anestisb/android-simg2img";
+    license = licenses.asl20;
+    platforms = platforms.linux;
+    maintainers = [ maintainers.dezgeg ];
+  };
+}
diff --git a/pkgs/tools/graphics/yaxg/default.nix b/pkgs/tools/graphics/yaxg/default.nix
new file mode 100644
index 000000000000..8fbc09a6d82b
--- /dev/null
+++ b/pkgs/tools/graphics/yaxg/default.nix
@@ -0,0 +1,38 @@
+{ stdenv, fetchFromGitHub, makeWrapper,
+  maim, slop, ffmpeg, byzanz, libnotify, xdpyinfo }:
+
+stdenv.mkDerivation rec {
+  name = "yaxg-${version}";
+  version = "unstable-2018-05-03";
+
+  src = fetchFromGitHub {
+    owner = "DanielFGray";
+    repo = "yaxg";
+    rev = "9d6af75da2ec25dba4b8d784e431064033d67ad2";
+    sha256 = "01p6ghp1vfrlnrm78bgbl9ppqwsdxh761g0qa172dpvsqg91l1p6";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+  buildInputs = [ maim slop ffmpeg byzanz libnotify xdpyinfo ];
+
+  installPhase = ''
+    mkdir -p $out/bin/
+    mv yaxg $out/bin/
+    chmod +x $out/bin/yaxg
+    wrapProgram $out/bin/yaxg --prefix PATH : ${ stdenv.lib.makeBinPath [ maim slop ffmpeg byzanz libnotify xdpyinfo ]}
+  '';
+
+  meta = with stdenv.lib; {
+    inherit (src.meta) homepage;
+    description = "Yet Another X Grabber script";
+    longDescription = ''
+      Capture and record your screen with callbacks. Wraps maim, slop, ffmpeg,
+      and byzanz to enable still image, video, or gif recording of part or all
+      of your screen. Similar command-line interface to scrot but is overall
+      more flexible and less buggy.
+    '';
+    platforms = platforms.all;
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ neonfuz ];
+  };
+}
diff --git a/pkgs/tools/misc/eot-utilities/default.nix b/pkgs/tools/misc/eot-utilities/default.nix
index b44159be8ce8..b9efead27988 100644
--- a/pkgs/tools/misc/eot-utilities/default.nix
+++ b/pkgs/tools/misc/eot-utilities/default.nix
@@ -17,6 +17,6 @@ stdenv.mkDerivation rec {
     description = "Create Embedded Open Type from OpenType or TrueType font";
     license = stdenv.lib.licenses.w3c;
     maintainers = with stdenv.lib.maintainers; [ leenaars ];
-    platforms = with stdenv.lib.platforms; linux; 
+    platforms = with stdenv.lib.platforms; unix;
   };
 }
diff --git a/pkgs/tools/networking/cntlm/default.nix b/pkgs/tools/networking/cntlm/default.nix
index efd2c17a43e3..6267e3a7790d 100644
--- a/pkgs/tools/networking/cntlm/default.nix
+++ b/pkgs/tools/networking/cntlm/default.nix
@@ -11,6 +11,11 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ which ];
 
+  preConfigure = stdenv.lib.optionalString stdenv.isDarwin ''
+    substituteInPlace configure --replace "xlc_r gcc" "xlc_r gcc $CC"
+    substitute Makefile Makefile.$CC --replace "CC=gcc" "CC=$CC"
+  '';
+
   installPhase = ''
     mkdir -p $out/bin; cp cntlm $out/bin/;
     mkdir -p $out/share/; cp COPYRIGHT README VERSION doc/cntlm.conf $out/share/;
@@ -21,11 +26,12 @@ stdenv.mkDerivation rec {
     description = "NTLM/NTLMv2 authenticating HTTP proxy";
     homepage = http://cntlm.sourceforge.net/;
     license = licenses.gpl2;
-    maintainers = 
+    maintainers =
       [
         maintainers.qknight
         maintainers.markWot
+        maintainers.carlosdagos
       ];
-    platforms = platforms.linux;
+    platforms = platforms.linux ++ platforms.darwin;
   };
 }
diff --git a/pkgs/tools/security/cfssl/default.nix b/pkgs/tools/security/cfssl/default.nix
index b3c256ae59bf..cce3370aeda1 100644
--- a/pkgs/tools/security/cfssl/default.nix
+++ b/pkgs/tools/security/cfssl/default.nix
@@ -2,15 +2,15 @@
 
 buildGoPackage rec {
   name = "cfssl-${version}";
-  version = "20170527";
+  version = "1.3.2";
 
   goPackagePath = "github.com/cloudflare/cfssl";
 
   src = fetchFromGitHub {
     owner = "cloudflare";
     repo = "cfssl";
-    rev = "114dc9691ec7bf3dac49d5953eccf7d91a0e0904";
-    sha256 = "1ijq43mrzrf1gkgj5ssxq7sgy6sd4rl706dzqkq9krqv5f6kwhj1";
+    rev = version;
+    sha256 = "0j2gz2vl2pf7ir7sc7jrwmjnr67hk4qhxw09cjx132jbk337jc9x";
   };
 
   meta = with stdenv.lib; {
diff --git a/pkgs/tools/security/passff-host/default.nix b/pkgs/tools/security/passff-host/default.nix
new file mode 100644
index 000000000000..1bb621eab362
--- /dev/null
+++ b/pkgs/tools/security/passff-host/default.nix
@@ -0,0 +1,36 @@
+{ stdenv, fetchFromGitHub, python3, pass }:
+
+stdenv.mkDerivation rec {
+  name = "passff-host-${version}";
+  version = "1.0.2";
+
+  src = fetchFromGitHub {
+    owner = "passff";
+    repo = "passff-host";
+    rev = version;
+    sha256 = "1zks34rg9i8vphjrj1h80y5rijadx33z911qxa7pslf7ahmjqdv3";
+  };
+
+  buildInputs = [ python3 ];
+
+  patchPhase = ''
+    sed -i 's#COMMAND      = "pass"#COMMAND = "${pass}/bin/pass"#' src/passff.py
+  '';
+
+  preBuild = "cd src";
+  postBuild = "cd ..";
+
+  installPhase = ''
+    install -D bin/testing/passff.py $out/share/passff-host/passff.py
+    cp bin/testing/passff.json $out/share/passff-host/passff.json
+    substituteInPlace $out/share/passff-host/passff.json \
+      --replace PLACEHOLDER $out/share/passff-host/passff.py
+  '';
+
+  meta = with stdenv.lib; {
+    description = "Host app for the WebExtension PassFF";
+    homepage = https://github.com/passff/passff-host;
+    license = licenses.gpl2;
+    maintainers = with maintainers; [ nadrieril ];
+  };
+}
diff --git a/pkgs/tools/system/bfs/default.nix b/pkgs/tools/system/bfs/default.nix
index fd7f93d1546c..56b7b26c7bd4 100644
--- a/pkgs/tools/system/bfs/default.nix
+++ b/pkgs/tools/system/bfs/default.nix
@@ -11,8 +11,6 @@ stdenv.mkDerivation rec {
     sha256 = "01vcqanj2sifa5i51wvrkxh55d6hrq6iq7zmnhv4ls221dqmbyyn";
   };
 
-  # Disable fstype test, tries to read /etc/mtab
-  patches = [ ./tests.patch ];
   postPatch = ''
     # Patch tests (both shebangs and usage in scripts)
     for f in $(find -type f -name '*.sh'); do
diff --git a/pkgs/tools/system/bfs/tests.patch b/pkgs/tools/system/bfs/tests.patch
deleted file mode 100644
index a30291d7095f..000000000000
--- a/pkgs/tools/system/bfs/tests.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/tests.sh
-+++ b/tests.sh
-@@ -369,7 +369,6 @@
-     test_printf_nul
-     test_quit_after_print
-     test_quit_before_print
--    test_fstype
-     test_not
-     test_and
-     test_or
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index a8844e3949e0..d8388bab0932 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -34,7 +34,8 @@ with pkgs;
       extraPackages = [];
       inherit bintools;
     };
-    allowedRequisites = stdenv.allowedRequisites ++ [ bintools ];
+    allowedRequisites =
+      lib.mapNullable (rs: rs ++ [ bintools ]) (stdenv.allowedRequisites or null);
   };
 
   # For convenience, allow callers to get the path to Nixpkgs.
@@ -693,6 +694,8 @@ with pkgs;
 
   browserpass = callPackage ../tools/security/browserpass { };
 
+  passff-host = callPackage ../tools/security/passff-host { };
+
   oracle-instantclient = callPackage ../development/libraries/oracle-instantclient { };
 
   kwakd = callPackage ../servers/kwakd { };
@@ -1439,6 +1442,8 @@ with pkgs;
 
   s2png = callPackage ../tools/graphics/s2png { };
 
+  simg2img = callPackage ../tools/filesystems/simg2img { };
+
   socklog = callPackage ../tools/system/socklog { };
 
   staccato = callPackage ../tools/text/staccato { };
@@ -8283,6 +8288,8 @@ with pkgs;
 
   kube-aws = callPackage ../development/tools/kube-aws { };
 
+  kustomize = callPackage ../development/tools/kustomize { };
+
   Literate = callPackage ../development/tools/literate-programming/Literate {};
 
   lcov = callPackage ../development/tools/analysis/lcov { };
@@ -16967,6 +16974,8 @@ with pkgs;
 
   kubernetes-helm = callPackage ../applications/networking/cluster/helm { };
 
+  kubetail = callPackage ../applications/networking/cluster/kubetail { } ;
+
   kupfer = callPackage ../applications/misc/kupfer { };
 
   lame = callPackage ../development/libraries/lame { };
@@ -18707,12 +18716,6 @@ with pkgs;
     inherit (darwin.apple_sdk.frameworks) CoreServices Cocoa Foundation CoreData;
     inherit (darwin) libobjc cf-private;
     inherit lua;
-
-    features = "huge"; # one of  tiny, small, normal, big or huge
-    gui = config.vim.gui or "auto";
-
-    # optional features by flags
-    flags = [ "python" "X11" ]; # only flag "X11" by now
   });
 
   vimNox = lowPrio (vim_configurable.override {
@@ -21823,6 +21826,8 @@ with pkgs;
 
   yara = callPackage ../tools/security/yara { };
 
+  yaxg = callPackage ../tools/graphics/yaxg {};
+
   zap = callPackage ../tools/networking/zap { };
 
   zdfmediathk = callPackage ../applications/video/zdfmediathk { };