about summary refs log tree commit diff
path: root/pkgs/development
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development')
-rw-r--r--pkgs/development/compilers/ats2/default.nix8
-rw-r--r--pkgs/development/compilers/ats2/installed-lib-directory-version.patch99
-rw-r--r--pkgs/development/compilers/crystal/default.nix99
-rw-r--r--pkgs/development/compilers/dmd/default.nix4
-rw-r--r--pkgs/development/compilers/ghcjs/base.nix1
-rw-r--r--pkgs/development/compilers/haxe/default.nix8
-rw-r--r--pkgs/development/compilers/haxe/haxelib-nix.patch34
-rw-r--r--pkgs/development/haskell-modules/configuration-ghc-head.nix1
-rw-r--r--pkgs/development/haskell-modules/configuration-hackage2nix.yaml6
-rw-r--r--pkgs/development/haskell-modules/generic-builder.nix32
-rw-r--r--pkgs/development/haskell-modules/hackage-packages.nix794
-rw-r--r--pkgs/development/interpreters/python/cpython/2.7/default.nix11
-rw-r--r--pkgs/development/interpreters/python/cpython/2.7/no-ldconfig.patch44
-rw-r--r--pkgs/development/interpreters/python/cpython/3.6/default.nix4
-rw-r--r--pkgs/development/interpreters/ruby/default.nix11
-rw-r--r--pkgs/development/interpreters/ruby/patchsets.nix5
-rw-r--r--pkgs/development/interpreters/ruby/rvm-patchsets.nix6
-rw-r--r--pkgs/development/libraries/SDL2/default.nix3
-rw-r--r--pkgs/development/libraries/cairo/default.nix4
-rw-r--r--pkgs/development/libraries/cyrus-sasl/default.nix3
-rw-r--r--pkgs/development/libraries/glib/default.nix7
-rw-r--r--pkgs/development/libraries/gtk+/3.x.nix4
-rw-r--r--pkgs/development/libraries/json-glib/default.nix2
-rw-r--r--pkgs/development/libraries/kerberos/krb5.nix9
-rw-r--r--pkgs/development/libraries/kerberos/path_char_fix.patch38
-rw-r--r--pkgs/development/libraries/libuv/default.nix14
-rw-r--r--pkgs/development/libraries/libwacom/default.nix4
-rw-r--r--pkgs/development/libraries/ncurses/default.nix3
-rw-r--r--pkgs/development/libraries/nghttp2/default.nix14
-rw-r--r--pkgs/development/libraries/science/biology/htslib/default.nix4
-rw-r--r--pkgs/development/libraries/simgear/default.nix10
-rw-r--r--pkgs/development/libraries/wxmac/default.nix47
-rw-r--r--pkgs/development/libraries/wxmac/wx.patch59
-rw-r--r--pkgs/development/libraries/zlib/CVE-2016-9840.patch71
-rw-r--r--pkgs/development/libraries/zlib/CVE-2016-9841.patch224
-rw-r--r--pkgs/development/libraries/zlib/CVE-2016-9842.patch29
-rw-r--r--pkgs/development/libraries/zlib/CVE-2016-9843.patch49
-rw-r--r--pkgs/development/libraries/zlib/default.nix8
-rw-r--r--pkgs/development/python-modules/pandas/default.nix91
-rw-r--r--pkgs/development/python-modules/pycairo/default.nix2
-rw-r--r--pkgs/development/python-modules/pygame/git.nix1
-rw-r--r--pkgs/development/python-modules/pytest-expect/default.nix31
-rw-r--r--pkgs/development/python-modules/u-msgpack-python/default.nix33
-rw-r--r--pkgs/development/python-modules/webencodings/default.nix29
-rw-r--r--pkgs/development/python-modules/xlwt/default.nix36
-rw-r--r--pkgs/development/tools/build-managers/cmake/default.nix11
-rw-r--r--pkgs/development/tools/build-managers/shards/default.nix28
-rw-r--r--pkgs/development/tools/continuous-integration/gitlab-runner/default.nix10
-rw-r--r--pkgs/development/tools/libsigrokdecode/default.nix4
-rw-r--r--pkgs/development/tools/misc/cscope/default.nix2
-rw-r--r--pkgs/development/tools/pypi2nix/default.nix17
51 files changed, 1585 insertions, 483 deletions
diff --git a/pkgs/development/compilers/ats2/default.nix b/pkgs/development/compilers/ats2/default.nix
index 97e95b29814d..59ce006e8357 100644
--- a/pkgs/development/compilers/ats2/default.nix
+++ b/pkgs/development/compilers/ats2/default.nix
@@ -3,11 +3,11 @@
 , withContrib ? true }:
 
 let
-  versionPkg = "0.2.12" ;
+  versionPkg = "0.2.13" ;
 
   contrib = fetchurl {
     url = "mirror://sourceforge/ats2-lang/ATS2-Postiats-contrib-${versionPkg}.tgz" ;
-    sha256 = "16jzabmwq5yz72dzlkc2hmvf2lan83gayn21gbl65jgpwdsbh170" ;
+    sha256 = "1hsqvdwiydks46sfjmm04rmjcx5v25xpjgnq0b96psrdbd0ky2kf" ;
   };
 
   postInstallContrib = stdenv.lib.optionalString withContrib
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   src = fetchurl {
     url = "mirror://sourceforge/ats2-lang/ATS2-Postiats-${version}.tgz";
-    sha256 = "0m8gmm1pnklixxw76yjjqqqixm2cyp91rnq4sj1k29qp4k9zxpl4";
+    sha256 = "01rkybkwgbpx6blv72n46ml9ii3p6kpxbpczsrpbjkqmf22b4vii";
   };
 
   buildInputs = [ gmp ];
@@ -45,8 +45,6 @@ stdenv.mkDerivation rec {
       builtins.toFile "setupHook.sh"
       (concatMapStringsSep "\n" builtins.readFile hookFiles);
 
-  patches = [ ./installed-lib-directory-version.patch ];
-
   postInstall = postInstallContrib + postInstallEmacs;
 
   meta = with stdenv.lib; {
diff --git a/pkgs/development/compilers/ats2/installed-lib-directory-version.patch b/pkgs/development/compilers/ats2/installed-lib-directory-version.patch
deleted file mode 100644
index 686df69299f2..000000000000
--- a/pkgs/development/compilers/ats2/installed-lib-directory-version.patch
+++ /dev/null
@@ -1,99 +0,0 @@
-Change the name of the library directory to match the version of the package.
-
-diff -Naur ATS2-Postiats-0.2.12/configure postiats-new/configure
---- ATS2-Postiats-0.2.12/configure	2016-10-13 12:03:20.000000000 -0400
-+++ postiats-new/configure	2016-10-23 20:17:29.912579618 -0400
-@@ -1,6 +1,6 @@
- #! /bin/sh
- # Guess values for system-dependent variables and create Makefiles.
--# Generated by GNU Autoconf 2.69 for ATS2/Postiats 0.2.10.
-+# Generated by GNU Autoconf 2.69 for ATS2/Postiats 0.2.12.
- #
- # Report bugs to <gmpostiats@gmail.com>.
- #
-@@ -580,8 +580,8 @@
- # Identity of this package.
- PACKAGE_NAME='ATS2/Postiats'
- PACKAGE_TARNAME='ats2-postiats'
--PACKAGE_VERSION='0.2.10'
--PACKAGE_STRING='ATS2/Postiats 0.2.10'
-+PACKAGE_VERSION='0.2.12'
-+PACKAGE_STRING='ATS2/Postiats 0.2.12'
- PACKAGE_BUGREPORT='gmpostiats@gmail.com'
- PACKAGE_URL=''
- 
-@@ -1242,7 +1242,7 @@
-   # Omit some internal or obsolete options to make the list less imposing.
-   # This message is too long to be a string in the A/UX 3.1 sh.
-   cat <<_ACEOF
--\`configure' configures ATS2/Postiats 0.2.10 to adapt to many kinds of systems.
-+\`configure' configures ATS2/Postiats 0.2.12 to adapt to many kinds of systems.
- 
- Usage: $0 [OPTION]... [VAR=VALUE]...
- 
-@@ -1304,7 +1304,7 @@
- 
- if test -n "$ac_init_help"; then
-   case $ac_init_help in
--     short | recursive ) echo "Configuration of ATS2/Postiats 0.2.10:";;
-+     short | recursive ) echo "Configuration of ATS2/Postiats 0.2.12:";;
-    esac
-   cat <<\_ACEOF
- 
-@@ -1384,7 +1384,7 @@
- test -n "$ac_init_help" && exit $ac_status
- if $ac_init_version; then
-   cat <<\_ACEOF
--ATS2/Postiats configure 0.2.10
-+ATS2/Postiats configure 0.2.12
- generated by GNU Autoconf 2.69
- 
- Copyright (C) 2012 Free Software Foundation, Inc.
-@@ -1936,7 +1936,7 @@
- This file contains any messages produced by compilers while
- running configure, to aid debugging if configure makes a mistake.
- 
--It was created by ATS2/Postiats $as_me 0.2.10, which was
-+It was created by ATS2/Postiats $as_me 0.2.12, which was
- generated by GNU Autoconf 2.69.  Invocation command line was
- 
-   $ $0 $@
-@@ -4226,7 +4226,7 @@
- # report actual input values of CONFIG_FILES etc. instead of their
- # values after options handling.
- ac_log="
--This file was extended by ATS2/Postiats $as_me 0.2.10, which was
-+This file was extended by ATS2/Postiats $as_me 0.2.12, which was
- generated by GNU Autoconf 2.69.  Invocation command line was
- 
-   CONFIG_FILES    = $CONFIG_FILES
-@@ -4288,7 +4288,7 @@
- cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
- ac_cs_version="\\
--ATS2/Postiats config.status 0.2.10
-+ATS2/Postiats config.status 0.2.12
- configured by $0, generated by GNU Autoconf 2.69,
-   with options \\"\$ac_cs_config\\"
- 
-diff -Naur ATS2-Postiats-0.2.12/src/CBOOT/config.h postiats-new/src/CBOOT/config.h
---- ATS2-Postiats-0.2.12/src/CBOOT/config.h	2016-10-13 12:03:20.000000000 -0400
-+++ postiats-new/src/CBOOT/config.h	2016-10-23 20:16:34.613836556 -0400
-@@ -44,7 +44,7 @@
- #define PACKAGE_NAME "ATS2/Postiats"
- 
- /* Define to the full name and version of this package. */
--#define PACKAGE_STRING "ATS2/Postiats 0.2.10"
-+#define PACKAGE_STRING "ATS2/Postiats 0.2.12"
- 
- /* Define to the one symbol short name of this package. */
- #define PACKAGE_TARNAME "ats2-postiats"
-@@ -53,7 +53,7 @@
- #define PACKAGE_URL ""
- 
- /* Define to the version of this package. */
--#define PACKAGE_VERSION "0.2.10"
-+#define PACKAGE_VERSION "0.2.12"
- 
- /* The size of `void*', as computed by sizeof. */
- #define SIZEOF_VOIDP 8
diff --git a/pkgs/development/compilers/crystal/default.nix b/pkgs/development/compilers/crystal/default.nix
new file mode 100644
index 000000000000..5bb3b60d96d5
--- /dev/null
+++ b/pkgs/development/compilers/crystal/default.nix
@@ -0,0 +1,99 @@
+{ stdenv, fetchurl, boehmgc, libatomic_ops, pcre, libevent, libiconv, llvm_39, makeWrapper }:
+
+stdenv.mkDerivation rec {
+  version = "0.20.3";
+  name = "crystal-${version}-1";
+  arch =
+    {
+      "x86_64-linux" = "linux-x86_64";
+      "i686-linux" = "linux-i686";
+      "x86_64-darwin" = "darwin-x86_64";
+    }."${stdenv.system}" or (throw "system ${stdenv.system} not supported");
+
+  prebuiltBinary = fetchurl {
+    url = "https://github.com/crystal-lang/crystal/releases/download/${version}/crystal-${version}-1-${arch}.tar.gz";
+    sha256 =
+      {
+        "x86_64-linux" = "c656dc8092a6161262f527df441aaab4ea9dd9a836a013f7155c6378b26b8cd7";
+        "i686-linux" = "85edfa1dda5e712341869bab87f6de0f7c6860e2a04dec2f00e8dc6aa1418611";
+        "x86_64-darwin" = "0088972c5cad9543f262976ae6c8ee1dbcbefdee3a8bedae851998bfa7098637";
+      }."${stdenv.system}" or (throw "system ${stdenv.system} not supported");
+  };
+
+  src = fetchurl {
+    url = "https://github.com/crystal-lang/crystal/archive/${version}.tar.gz";
+    sha256 = "5372ba2a35d885345207047a51b9389f9190fd12389847e7f7298618bcf59ad6";
+  };
+
+  # crystal on Darwin needs libiconv to build
+  buildInputs = [
+    boehmgc libatomic_ops pcre libevent llvm_39 makeWrapper
+  ] ++ stdenv.lib.optionals stdenv.isDarwin [
+    libiconv
+  ];
+
+  libPath = stdenv.lib.makeLibraryPath ([
+    boehmgc libatomic_ops pcre libevent
+  ] ++ stdenv.lib.optionals stdenv.isDarwin [
+    libiconv
+  ]);
+
+  unpackPhase = ''
+    tar zxf ${src}
+    tar zxf ${prebuiltBinary}
+  '';
+
+  sourceRoot = ".";
+
+  fixPrebuiltBinary = if stdenv.isDarwin then ''
+    wrapProgram $(pwd)/crystal-${version}-1/embedded/bin/crystal \
+        --suffix DYLD_LIBRARY_PATH : $libPath
+  ''
+  else ''
+    patchelf --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
+      crystal-${version}-1/embedded/bin/crystal
+    patchelf --set-rpath ${ stdenv.lib.makeLibraryPath [ stdenv.cc.cc ] } \
+      crystal-${version}-1/embedded/bin/crystal
+  '';
+
+  buildPhase = ''
+    # patch the script which launches the prebuilt compiler
+    substituteInPlace $(pwd)/crystal-${version}-1/bin/crystal --replace \
+      "/usr/bin/env bash" "${stdenv.shell}"
+    ${fixPrebuiltBinary}
+
+    cd crystal-${version}
+    make release=1 PATH="../crystal-${version}-1/bin:$PATH"
+    make doc
+  '';
+
+  installPhase = ''
+    install -Dm755 .build/crystal $out/bin/crystal
+    wrapProgram $out/bin/crystal \
+        --suffix CRYSTAL_PATH : $out/lib/crystal \
+        --suffix LIBRARY_PATH : $libPath
+
+    install -dm755 $out/lib/crystal
+    cp -r src/* $out/lib/crystal/
+
+    install -dm755 $out/share/doc/crystal/api
+    cp -r doc/* $out/share/doc/crystal/api/
+    cp -r samples $out/share/doc/crystal/
+
+    install -Dm644 etc/completion.bash $out/share/bash-completion/completions/crystal
+    install -Dm644 etc/completion.zsh $out/share/zsh/site-functions/_crystal
+
+    install -Dm644 LICENSE $out/share/licenses/crystal/LICENSE
+  '';
+
+  dontStrip = true;
+
+  meta = {
+    description = "A compiled language with Ruby like syntax and type inference";
+    homepage = "https://crystal-lang.org/";
+    license = stdenv.lib.licenses.asl20;
+    maintainers = with stdenv.lib.maintainers; [ mingchuan ];
+    platforms = [ "x86_64-linux" "i686-linux" "x86_64-darwin" ];
+  };
+}
+
diff --git a/pkgs/development/compilers/dmd/default.nix b/pkgs/development/compilers/dmd/default.nix
index 3435b94c32e6..41162c4e50e7 100644
--- a/pkgs/development/compilers/dmd/default.nix
+++ b/pkgs/development/compilers/dmd/default.nix
@@ -20,10 +20,6 @@ stdenv.mkDerivation rec {
       substituteInPlace src/dmd/posix.mak \
           --replace g++ clang++ \
           --replace MACOSX_DEPLOYMENT_TARGET MACOSX_DEPLOYMENT_TARGET_
-
-      # Was not able to compile on darwin due to "__inline_isnanl"
-      # being undefined.
-      substituteInPlace src/dmd/root/port.c --replace __inline_isnanl __inline_isnan
   '';
 
   # Buid and install are based on http://wiki.dlang.org/Building_DMD
diff --git a/pkgs/development/compilers/ghcjs/base.nix b/pkgs/development/compilers/ghcjs/base.nix
index f8b861311d60..393278be49ef 100644
--- a/pkgs/development/compilers/ghcjs/base.nix
+++ b/pkgs/development/compilers/ghcjs/base.nix
@@ -183,4 +183,5 @@ in mkDerivation (rec {
   license = stdenv.lib.licenses.bsd3;
   platforms = ghc.meta.platforms;
   maintainers = with stdenv.lib.maintainers; [ jwiegley cstrahan ];
+  broken = true;  # http://hydra.nixos.org/build/45110274
 })
diff --git a/pkgs/development/compilers/haxe/default.nix b/pkgs/development/compilers/haxe/default.nix
index a2afcc773802..a4077408ef00 100644
--- a/pkgs/development/compilers/haxe/default.nix
+++ b/pkgs/development/compilers/haxe/default.nix
@@ -1,17 +1,17 @@
 { stdenv, fetchgit, ocaml, zlib, neko, camlp4 }:
 
 stdenv.mkDerivation {
-  name = "haxe-3.1.3";
+  name = "haxe-3.2.1";
 
   buildInputs = [ocaml zlib neko camlp4];
 
   src = fetchgit {
     url = "https://github.com/HaxeFoundation/haxe.git";
-    sha256 = "0d8s9yqsqcbr2lfw4xnmg7vzgb6k1jq6hlwwaf1kmn9wxpvcc6x9";
+    sha256 = "1x9ay5a2llq46fww3k07jxx8h1vfpyxb522snc6702a050ki5vz3";
     fetchSubmodules = true;
 
-    # Tag 3.1.3
-    rev = "7be30670b2f1f9b6082499c8fb9e23c0a6df6c28";
+    # Tag 3.2.1
+    rev = "deab4424399b520750671e51e5f5c2684e942c17";
   };
 
   prePatch = ''
diff --git a/pkgs/development/compilers/haxe/haxelib-nix.patch b/pkgs/development/compilers/haxe/haxelib-nix.patch
index da7e4c8dacb8..ed370e8efd12 100644
--- a/pkgs/development/compilers/haxe/haxelib-nix.patch
+++ b/pkgs/development/compilers/haxe/haxelib-nix.patch
@@ -1,10 +1,10 @@
-diff --git a/extra/haxelib_src/src/tools/haxelib/Main.hx b/extra/haxelib_src/src/tools/haxelib/Main.hx
-index a44a785..0eb811a 100644
+diff --git a/src/tools/haxelib/Main.hx b/src/tools/haxelib/Main.hx
+index dc18815..def5231 100644
 --- a/extra/haxelib_src/src/tools/haxelib/Main.hx
 +++ b/extra/haxelib_src/src/tools/haxelib/Main.hx
-@@ -996,21 +996,26 @@ class Main {
+@@ -1301,21 +1301,26 @@ class Main {
  	}
- 
+
  	function checkRec( prj : String, version : String, l : List<{ project : String, version : String, info : Infos }> ) {
 -		var pdir = getRepository() + Data.safe(prj);
 -		if( !FileSystem.exists(pdir) )
@@ -44,7 +44,7 @@ index a44a785..0eb811a 100644
  		var json = try File.getContent(vdir+"/"+Data.JSON) catch( e : Dynamic ) null;
  		var inf = Data.readData(json,false);
  		l.add({ project : prj, version : version, info: inf });
-@@ -1025,15 +1030,21 @@ class Main {
+@@ -1330,15 +1335,21 @@ class Main {
  			var a = args[argcur++].split(":");
  			checkRec(a[0],a[1],list);
  		}
@@ -73,10 +73,10 @@ index a44a785..0eb811a 100644
  			var ndir = dir + "ndll";
  			if( FileSystem.exists(ndir) ) {
  				var sysdir = ndir+"/"+Sys.systemName();
-@@ -1153,21 +1164,39 @@ class Main {
- 		print('  Path: $devPath');
+@@ -1491,23 +1502,43 @@ class Main {
+ 			);
  	}
- 
+
 +	function getNixLib(project:String):Null<String>
 +	{
 +		var hlibPath = Sys.getEnv("HAXELIB_PATH");
@@ -91,7 +91,7 @@ index a44a785..0eb811a 100644
 +		}
 +		return null;
 +	}
-+
+
  	function run() {
 -		var rep = getRepository();
  		var project = param("Library");
@@ -103,10 +103,10 @@ index a44a785..0eb811a 100644
 -		pdir += "/";
 -		var version = temp[1] != null ? temp[1] : getCurrent(pdir);
 -		var dev = try getDev(pdir) catch ( e : Dynamic ) null;
--		var vdir = dev!=null ? dev : pdir + Data.safe(version);
--		var rdir = vdir + "/run.n";
--		if( !FileSystem.exists(rdir) )
--			throw "Library "+project+" version "+version+" does not have a run script";
+-		var vdir = dev != null ? dev : pdir + Data.safe(version);
+
+ 		args.push(cli.cwd);
++
 +		var vdir = this.getNixLib(project);
 +		if (vdir == null) {
 +			var rep = getRepository();
@@ -121,6 +121,8 @@ index a44a785..0eb811a 100644
 +			if( !FileSystem.exists(rdir) )
 +				throw "Library "+project+" version "+version+" does not have a run script";
 +		}
- 		args.push(Sys.getCwd());
- 		Sys.setCwd(vdir);
- 		var cmd = "neko run.n";
+ 		cli.cwd = vdir;
+-
+ 		var callArgs =
+ 			switch try [Data.readData(File.getContent(vdir + '/haxelib.json'), false), null] catch (e:Dynamic) [null, e] {
+ 				case [null, e]:
diff --git a/pkgs/development/haskell-modules/configuration-ghc-head.nix b/pkgs/development/haskell-modules/configuration-ghc-head.nix
index 559096ebd28d..a2b6058b166e 100644
--- a/pkgs/development/haskell-modules/configuration-ghc-head.nix
+++ b/pkgs/development/haskell-modules/configuration-ghc-head.nix
@@ -19,6 +19,7 @@ self: super: {
   directory = null;
   filepath = null;
   ghc-prim = null;
+  ghci = null;
   haskeline = null;
   hoopl = null;
   hpc = null;
diff --git a/pkgs/development/haskell-modules/configuration-hackage2nix.yaml b/pkgs/development/haskell-modules/configuration-hackage2nix.yaml
index f766b2be8f56..42858390c306 100644
--- a/pkgs/development/haskell-modules/configuration-hackage2nix.yaml
+++ b/pkgs/development/haskell-modules/configuration-hackage2nix.yaml
@@ -3829,6 +3829,7 @@ dont-distribute-packages:
   git-date:                                     [ i686-linux, x86_64-linux, x86_64-darwin ]
   git-gpush:                                    [ i686-linux, x86_64-linux, x86_64-darwin ]
   git-jump:                                     [ i686-linux, x86_64-linux, x86_64-darwin ]
+  git-mediate:                                  [ i686-linux, x86_64-linux, x86_64-darwin ]
   git-object:                                   [ i686-linux, x86_64-linux, x86_64-darwin ]
   git-repair:                                   [ i686-linux, x86_64-linux, x86_64-darwin ]
   git-sanity:                                   [ i686-linux, x86_64-linux, x86_64-darwin ]
@@ -5440,6 +5441,7 @@ dont-distribute-packages:
   lzma-enumerator:                              [ i686-linux, x86_64-linux, x86_64-darwin ]
   maam:                                         [ i686-linux, x86_64-linux, x86_64-darwin ]
   macbeth-lib:                                  [ i686-linux, x86_64-linux, x86_64-darwin ]
+  machinecell:                                  [ i686-linux, x86_64-linux, x86_64-darwin ]
   machines-zlib:                                [ i686-linux, x86_64-linux, x86_64-darwin ]
   macosx-make-standalone:                       [ i686-linux, x86_64-linux, x86_64-darwin ]
   mage:                                         [ i686-linux, x86_64-linux, x86_64-darwin ]
@@ -5826,6 +5828,7 @@ dont-distribute-packages:
   newtype-generics:                             [ i686-linux, x86_64-linux, x86_64-darwin ]
   newtype-th:                                   [ i686-linux, x86_64-linux, x86_64-darwin ]
   next-ref:                                     [ i686-linux, x86_64-linux, x86_64-darwin ]
+  nfc:                                          [ i686-linux, x86_64-linux, x86_64-darwin ]
   ngrams-loader:                                [ i686-linux, x86_64-linux, x86_64-darwin ]
   NGrams:                                       [ i686-linux, x86_64-linux, x86_64-darwin ]
   niagra:                                       [ i686-linux, x86_64-linux, x86_64-darwin ]
@@ -6209,6 +6212,7 @@ dont-distribute-packages:
   press:                                        [ i686-linux, x86_64-linux, x86_64-darwin ]
   presto-hdbc:                                  [ i686-linux, x86_64-linux, x86_64-darwin ]
   pretty-error:                                 [ i686-linux, x86_64-linux, x86_64-darwin ]
+  pretty-simple:                                [ i686-linux, x86_64-linux, x86_64-darwin ]
   primitive-simd:                               [ i686-linux, x86_64-linux, x86_64-darwin ]
   PrimitiveArray-Pretty:                        [ i686-linux, x86_64-linux, x86_64-darwin ]
   primula-board:                                [ i686-linux, x86_64-linux, x86_64-darwin ]
@@ -7217,6 +7221,7 @@ dont-distribute-packages:
   texrunner:                                    [ i686-linux, x86_64-linux, x86_64-darwin ]
   text-all:                                     [ i686-linux, x86_64-linux, x86_64-darwin ]
   text-and-plots:                               [ i686-linux, x86_64-linux, x86_64-darwin ]
+  text-icu-normalized:                          [ i686-linux, x86_64-linux, x86_64-darwin ]
   text-json-qq:                                 [ i686-linux, x86_64-linux, x86_64-darwin ]
   text-normal:                                  [ i686-linux, x86_64-linux, x86_64-darwin ]
   text-position:                                [ i686-linux, x86_64-linux, x86_64-darwin ]
@@ -7705,6 +7710,7 @@ dont-distribute-packages:
   wxFruit:                                      [ i686-linux, x86_64-linux, x86_64-darwin ]
   WxGeneric:                                    [ i686-linux, x86_64-linux, x86_64-darwin ]
   wxhnotepad:                                   [ i686-linux, x86_64-linux, x86_64-darwin ]
+  wxSimpleCanvas:                               [ i686-linux, x86_64-linux, x86_64-darwin ]
   wxturtle:                                     [ i686-linux, x86_64-linux, x86_64-darwin ]
   wyvern:                                       [ i686-linux, x86_64-linux, x86_64-darwin ]
   x-dsp:                                        [ i686-linux, x86_64-linux, x86_64-darwin ]
diff --git a/pkgs/development/haskell-modules/generic-builder.nix b/pkgs/development/haskell-modules/generic-builder.nix
index f91bd474c6fd..dfe9f68ec617 100644
--- a/pkgs/development/haskell-modules/generic-builder.nix
+++ b/pkgs/development/haskell-modules/generic-builder.nix
@@ -245,9 +245,41 @@ stdenv.mkDerivation ({
     runHook postConfigure
   '';
 
+  # The darwin pre/post build sections are a workaround https://github.com/haskell/cabal/issues/4183
+  # It seems like --extra-lib-dirs from the previous steps is not detected properly,
+  # to work around this we build using a DYLD_LIBRARY_PATH and fixup the build afterwards.
   buildPhase = ''
     runHook preBuild
+    ${optionalString stdenv.isDarwin ''
+      local inputClosure=""
+      for i in $propagatedNativeBuildInputs $nativeBuildInputs; do
+        findInputs $i inputClosure propagated-native-build-inputs
+      done
+      local -a inputLibs=()
+      for p in $inputClosure; do
+        if [ -d "$p/lib/${ghc.name}/package.conf.d" ]; then
+          continue
+        fi
+        if [ -d "$p/lib" ]; then
+          inputLibs+="$p/lib"
+        fi
+      done
+
+      for lib in $inputLibs; do
+        export DYLD_LIBRARY_PATH="$lib:''${DYLD_LIBRARY_PATH:+:$DYLD_LIBRARY_PATH}"
+      done
+    ''}
     ${setupCommand} build ${buildTarget}${crossCabalFlagsString}
+    ${optionalString stdenv.isDarwin ''
+      unset DYLD_LIBRARY_PATH
+
+      local outputLib=dist/build/*-ghc${ghc.version}.dylib
+      for lib in $inputLib/*.dylib; do
+        for name in $(otool -L $outputLib | awk '$1 ~ /^'$(basename lib)'/ {print $1}' | cat); do
+          install_name_tool -change $name $lib $outputLib
+        done
+      done
+    ''}
     runHook postBuild
   '';
 
diff --git a/pkgs/development/haskell-modules/hackage-packages.nix b/pkgs/development/haskell-modules/hackage-packages.nix
index 1bdf1256369a..8b917a56a908 100644
--- a/pkgs/development/haskell-modules/hackage-packages.nix
+++ b/pkgs/development/haskell-modules/hackage-packages.nix
@@ -726,35 +726,33 @@ self: {
        maintainers = with stdenv.lib.maintainers; [ abbradar ];
      }) {inherit (pkgs) emacs;};
 
-  "Agda_2_5_1_2" = callPackage
+  "Agda_2_5_2" = callPackage
     ({ mkDerivation, alex, array, base, binary, boxes, bytestring
-     , containers, cpphs, data-hash, deepseq, directory, EdisonAPI
-     , EdisonCore, edit-distance, emacs, equivalence, filemanip
-     , filepath, geniplate-mirror, happy, hashable, hashtables
-     , haskeline, haskell-src-exts, monadplus, mtl, parallel, pretty
-     , process, QuickCheck, strict, template-haskell, text, time
-     , transformers, transformers-compat, unordered-containers, xhtml
-     , zlib
+     , containers, cpphs, data-hash, deepseq, directory, EdisonCore
+     , edit-distance, emacs, equivalence, filepath, geniplate-mirror
+     , gitrev, happy, hashable, hashtables, haskeline, ieee754
+     , monadplus, mtl, murmur-hash, parallel, pretty, process
+     , regex-tdfa, strict, template-haskell, text, time, transformers
+     , transformers-compat, unordered-containers, xhtml, zlib
      }:
      mkDerivation {
        pname = "Agda";
-       version = "2.5.1.2";
-       sha256 = "fb272bd6f7d532320c669b96faa85088b37bae02d906e9a9f764bc8e8639fb5e";
+       version = "2.5.2";
+       sha256 = "d812cec3bf7f03c4b27248572475c7e060154102771a8434cc11ba89f5691439";
+       revision = "1";
+       editedCabalFile = "44f0f96c5d26202f964c575e5f94fe52686f4b889078ddfdafef0c6fd2571b47";
        isLibrary = true;
        isExecutable = true;
        libraryHaskellDepends = [
          array base binary boxes bytestring containers data-hash deepseq
-         directory EdisonAPI EdisonCore edit-distance equivalence filepath
-         geniplate-mirror hashable hashtables haskeline haskell-src-exts
-         monadplus mtl parallel pretty process QuickCheck strict
+         directory EdisonCore edit-distance equivalence filepath
+         geniplate-mirror gitrev hashable hashtables haskeline ieee754
+         monadplus mtl murmur-hash parallel pretty process regex-tdfa strict
          template-haskell text time transformers transformers-compat
          unordered-containers xhtml zlib
        ];
        libraryToolDepends = [ alex cpphs happy ];
-       executableHaskellDepends = [
-         base binary containers directory filemanip filepath
-         haskell-src-exts mtl process
-       ];
+       executableHaskellDepends = [ base directory filepath process ];
        executableToolDepends = [ emacs ];
        postInstall = ''
          files=("$out/share/"*"-ghc-"*"/Agda-"*"/lib/prim/Agda/"{Primitive.agda,Builtin"/"*.agda})
@@ -1388,6 +1386,23 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
+  "BioHMM" = callPackage
+    ({ mkDerivation, base, colour, diagrams-cairo, diagrams-lib
+     , directory, either-unwrap, filepath, parsec, ParsecTools
+     , StockholmAlignment, SVGFonts, text, vector
+     }:
+     mkDerivation {
+       pname = "BioHMM";
+       version = "1.0.1";
+       sha256 = "b20fbbd9e38b9f764a9152aa123bbf7296b4be361bddfc7e1bbe833d439f9c20";
+       libraryHaskellDepends = [
+         base colour diagrams-cairo diagrams-lib directory either-unwrap
+         filepath parsec ParsecTools StockholmAlignment SVGFonts text vector
+       ];
+       description = "Libary containing parsing and visualisation functions and datastructures for Hidden Markov Models in HMMER3 format";
+       license = stdenv.lib.licenses.gpl3;
+     }) {};
+
   "Biobase" = callPackage
     ({ mkDerivation, array, base, bytestring, containers, deepseq
      , directory, either-unwrap, file-embed, filemanip, filepath
@@ -16061,6 +16076,23 @@ self: {
        license = stdenv.lib.licenses.gpl3;
      }) {};
 
+  "StockholmAlignment" = callPackage
+    ({ mkDerivation, base, colour, diagrams-cairo, diagrams-lib
+     , directory, either-unwrap, filepath, parsec, ParsecTools, SVGFonts
+     , text, vector
+     }:
+     mkDerivation {
+       pname = "StockholmAlignment";
+       version = "1.0.0";
+       sha256 = "0b1234009521e37f69d734391138bec11c7c3d2df2496c939268fbff2cb1c86b";
+       libraryHaskellDepends = [
+         base colour diagrams-cairo diagrams-lib directory either-unwrap
+         filepath parsec ParsecTools SVGFonts text vector
+       ];
+       description = "Libary for Stockholm aligmnent format";
+       license = stdenv.lib.licenses.gpl3;
+     }) {};
+
   "Stomp" = callPackage
     ({ mkDerivation, base, binary, bytestring, network, time
      , utf8-string
@@ -24252,6 +24284,30 @@ self: {
        hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
+  "amazonka-s3-streaming" = callPackage
+    ({ mkDerivation, amazonka, amazonka-core, amazonka-s3, base
+     , bytestring, conduit, conduit-extra, dlist, exceptions, lens
+     , lifted-async, mmap, mmorph, mtl, resourcet, text
+     }:
+     mkDerivation {
+       pname = "amazonka-s3-streaming";
+       version = "0.1.0.4";
+       sha256 = "ecd0dfe5b024a326e96224ba6f406b44f1279eaef4d44904167a8f5a1f3d881d";
+       isLibrary = true;
+       isExecutable = true;
+       libraryHaskellDepends = [
+         amazonka amazonka-core amazonka-s3 base bytestring conduit dlist
+         exceptions lens lifted-async mmap mmorph mtl resourcet
+       ];
+       executableHaskellDepends = [
+         amazonka amazonka-core amazonka-s3 base bytestring conduit
+         conduit-extra text
+       ];
+       homepage = "https://github.com/Axman6/amazonka-s3-streaming#readme";
+       description = "Provides conduits to upload data to S3 using the Multipart API";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
   "amazonka-sdb" = callPackage
     ({ mkDerivation, amazonka-core, amazonka-test, base, bytestring
      , tasty, tasty-hunit, text, time, unordered-containers
@@ -25250,6 +25306,19 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
+  "anonymous-sums_0_6_0_0" = callPackage
+    ({ mkDerivation, base, lens, template-haskell }:
+     mkDerivation {
+       pname = "anonymous-sums";
+       version = "0.6.0.0";
+       sha256 = "c7c5c13cb19ce97fdb621794cd1de7e34ab7aba8bdc5bcc9309107b1ff3ec2ad";
+       libraryHaskellDepends = [ base lens template-haskell ];
+       homepage = "http://www.github.com/massysett/anonymous-sums";
+       description = "Anonymous sum types";
+       license = stdenv.lib.licenses.bsd3;
+       hydraPlatforms = stdenv.lib.platforms.none;
+     }) {};
+
   "anonymous-sums-tests" = callPackage
     ({ mkDerivation, anonymous-sums, base, QuickCheck }:
      mkDerivation {
@@ -25983,8 +26052,8 @@ self: {
     ({ mkDerivation, aeson, base, bytestring, lens, wreq }:
      mkDerivation {
        pname = "apioiaf-client";
-       version = "0.1.0.0";
-       sha256 = "8493248ae0d1303afba5f600e7c38fb29b6811d2348f994af056413a3ebbd0ff";
+       version = "0.2.1.0";
+       sha256 = "15561082ee74c3a64786347f9d8206896b70b1d3475e9dfa0318e2ed84703c6a";
        libraryHaskellDepends = [ aeson base bytestring lens wreq ];
        testHaskellDepends = [ base ];
        homepage = "https://github.com/kberger/anapioficeandfire-haskell#readme";
@@ -28601,8 +28670,8 @@ self: {
        pname = "avers";
        version = "0.0.17.0";
        sha256 = "3e6b4a39ccb99373a1a574625b86d4948f4ba4a747652e3c5ddd8d8b09fe212d";
-       revision = "1";
-       editedCabalFile = "76f5fea6b94a6dd6041577fd29de245130f3003c73296a94baea62f066b9b474";
+       revision = "3";
+       editedCabalFile = "dd1745f57f0636a5932c361e931feec895221ae612acc37eaf2d819f349c75ae";
        libraryHaskellDepends = [
          aeson attoparsec base bytestring clock containers cryptonite
          filepath inflections memory MonadRandom mtl network network-uri
@@ -28669,8 +28738,8 @@ self: {
        pname = "avers-server";
        version = "0.0.17.0";
        sha256 = "6da0c28f2b75989805cb4c2c7bf10b1b6ac4211f310d2bb902a4a7725ce05c3c";
-       revision = "1";
-       editedCabalFile = "8fb371992bc5535a3d923ec6e16e975ac3d5efaadbb1ae8d4e08400b318f92dc";
+       revision = "3";
+       editedCabalFile = "025cc10ba6aa604876978781fcfbffbce27867d9155257411a7a40d4c4687988";
        libraryHaskellDepends = [
          aeson avers avers-api base base64-bytestring bytestring
          bytestring-conversion containers cookie cryptonite either
@@ -28824,6 +28893,42 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
+  "aws_0_15" = callPackage
+    ({ mkDerivation, aeson, attoparsec, base, base16-bytestring
+     , base64-bytestring, blaze-builder, byteable, bytestring
+     , case-insensitive, cereal, conduit, conduit-extra, containers
+     , cryptohash, data-default, directory, errors, filepath
+     , http-client, http-client-tls, http-conduit, http-types
+     , lifted-base, monad-control, mtl, network, old-locale, QuickCheck
+     , quickcheck-instances, resourcet, safe, scientific, tagged, tasty
+     , tasty-hunit, tasty-quickcheck, text, time, transformers
+     , transformers-base, unordered-containers, utf8-string, vector
+     , xml-conduit
+     }:
+     mkDerivation {
+       pname = "aws";
+       version = "0.15";
+       sha256 = "53c73595bddd5614d980486a380d4ce83c100fd25b5fa35d477609f1bd03b11b";
+       libraryHaskellDepends = [
+         aeson attoparsec base base16-bytestring base64-bytestring
+         blaze-builder byteable bytestring case-insensitive cereal conduit
+         conduit-extra containers cryptohash data-default directory filepath
+         http-conduit http-types lifted-base monad-control mtl network
+         old-locale resourcet safe scientific tagged text time transformers
+         unordered-containers utf8-string vector xml-conduit
+       ];
+       testHaskellDepends = [
+         aeson base bytestring errors http-client http-client-tls http-types
+         lifted-base monad-control mtl QuickCheck quickcheck-instances
+         resourcet tagged tasty tasty-hunit tasty-quickcheck text time
+         transformers transformers-base
+       ];
+       homepage = "http://github.com/aristidb/aws";
+       description = "Amazon Web Services (AWS) for Haskell";
+       license = stdenv.lib.licenses.bsd3;
+       hydraPlatforms = stdenv.lib.platforms.none;
+     }) {};
+
   "aws-cloudfront-signer" = callPackage
     ({ mkDerivation, asn1-encoding, asn1-types, base, base64-bytestring
      , bytestring, crypto-pubkey-types, RSA, time
@@ -34286,18 +34391,23 @@ self: {
 
   "bolt" = callPackage
     ({ mkDerivation, base, bifunctors, bytestring, cereal, containers
-     , hashable, network, network-uri, scientific, text, transformers
-     , unordered-containers, vector
+     , hashable, network, network-uri, scientific, tasty
+     , tasty-quickcheck, text, transformers, unordered-containers
+     , vector
      }:
      mkDerivation {
        pname = "bolt";
-       version = "0.2.0.0";
-       sha256 = "2a066c5e24a707c7fb418b34c01b7dc0f47b084eb621baefa3a79afe03640e12";
+       version = "0.2.2.0";
+       sha256 = "07d04b418f1106f4fb4e11f8466d18121f7d63d162e86389a69a58f23270339b";
        libraryHaskellDepends = [
          base bifunctors bytestring cereal containers hashable network
          network-uri scientific text transformers unordered-containers
          vector
        ];
+       testHaskellDepends = [
+         base bytestring cereal tasty tasty-quickcheck text
+         unordered-containers vector
+       ];
        homepage = "https://github.com/bflyblue/bolt#readme";
        description = "Bolt driver for Neo4j";
        license = stdenv.lib.licenses.bsd3;
@@ -34618,8 +34728,8 @@ self: {
     ({ mkDerivation, base, gtk, transformers, X11 }:
      mkDerivation {
        pname = "boring-window-switcher";
-       version = "0.1.0.1";
-       sha256 = "4d966b56d3a6badb666c8947df23557db9544e469514d0a5b68934c644f5645b";
+       version = "0.1.0.2";
+       sha256 = "e7e568de0b410fd878c6cd6ce9eae66f51e3e98c83090ad5dec23b5738c9721f";
        isLibrary = true;
        isExecutable = true;
        libraryHaskellDepends = [ base gtk transformers X11 ];
@@ -35172,9 +35282,9 @@ self: {
 
   "buchhaltung" = callPackage
     ({ mkDerivation, aeson, ansi-wl-pprint, array, async, base, boxes
-     , bytestring, Cabal, cassava, containers, data-default, Decimal
-     , deepseq, directory, edit-distance, file-embed, filepath
-     , formatting, hashable, haskeline, hint, hledger, hledger-lib, lens
+     , bytestring, cassava, containers, data-default, Decimal, deepseq
+     , directory, edit-distance, file-embed, filepath, formatting
+     , hashable, haskeline, hint, hledger, hledger-lib, lens
      , lifted-base, ListLike, megaparsec, MissingH, monad-control, mtl
      , optparse-applicative, parsec, process, regex-compat, regex-tdfa
      , regex-tdfa-text, safe, semigroups, split, strict, temporary, text
@@ -35182,11 +35292,10 @@ self: {
      }:
      mkDerivation {
        pname = "buchhaltung";
-       version = "0.0.1";
-       sha256 = "fd2dd47210a9d7200c0d4259646963b6bc848ff656255b66b14648b949dec70f";
+       version = "0.0.3";
+       sha256 = "6ba38b02094431f1f24e698eed4b4dc3c0169f2154d2b66a584c16162c4cf276";
        isLibrary = false;
        isExecutable = true;
-       setupHaskellDepends = [ base Cabal ];
        executableHaskellDepends = [
          aeson ansi-wl-pprint array async base boxes bytestring cassava
          containers data-default Decimal deepseq directory edit-distance
@@ -39940,6 +40049,18 @@ self: {
        hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
+  "choice" = callPackage
+    ({ mkDerivation, base }:
+     mkDerivation {
+       pname = "choice";
+       version = "0.1.1.0";
+       sha256 = "96245c66c3e2dd48aec6b9bba3198b336d4d111b10781e53c544b43b98c1a989";
+       libraryHaskellDepends = [ base ];
+       homepage = "https://github.com/mboes/choice#readme";
+       description = "A solution to boolean blindness";
+       license = stdenv.lib.licenses.publicDomain;
+     }) {};
+
   "choose" = callPackage
     ({ mkDerivation, base, MonadRandom }:
      mkDerivation {
@@ -41671,8 +41792,10 @@ self: {
      }:
      mkDerivation {
        pname = "clit";
-       version = "0.1.1.1";
-       sha256 = "bb2be5226f6659b709b87ebe593c7c1a2b9447d2b681dc9c97130254ba4e4a61";
+       version = "0.1.1.2";
+       sha256 = "5daac994e7e122d6e009cfbb8e87c9a6134c7157256d2c64dfb87d8b83503367";
+       revision = "1";
+       editedCabalFile = "a00ced1d7dcc50bae6eae37b415f304271ee08bec06b3d15f7ec60fe927bdad8";
        isLibrary = true;
        isExecutable = true;
        libraryHaskellDepends = [
@@ -43900,8 +44023,8 @@ self: {
      }:
      mkDerivation {
        pname = "concurrent-machines";
-       version = "0.2.3.1";
-       sha256 = "6d67692d241a0e160ace89ecd8bbb2e28cc90651c7d9996f6686de7856731eee";
+       version = "0.2.3.3";
+       sha256 = "e5204231e35181e56b9313f6dbe83d531b3f6c3f6dfbe3a1c465e5b6b2a24924";
        libraryHaskellDepends = [
          async base containers lifted-async machines monad-control
          semigroups time transformers transformers-base
@@ -47864,8 +47987,8 @@ self: {
      }:
      mkDerivation {
        pname = "cryptonite-openssl";
-       version = "0.3";
-       sha256 = "43c8f8b4259f103be4408734f604c55a0053e60d302890174ba4773828bdee26";
+       version = "0.4";
+       sha256 = "a8307454de4f85456660686815169d925cb90345f7ac016d0c5562c2755667ea";
        libraryHaskellDepends = [ base bytestring cryptonite memory ];
        librarySystemDepends = [ openssl ];
        testHaskellDepends = [
@@ -51869,18 +51992,19 @@ self: {
        license = stdenv.lib.licenses.mit;
      }) {};
 
-  "declarative_0_4_0" = callPackage
-    ({ mkDerivation, base, hasty-hamiltonian, lens, mcmc-types
-     , mighty-metropolis, mwc-probability, pipes, primitive
+  "declarative_0_5_1" = callPackage
+    ({ mkDerivation, base, hasty-hamiltonian, kan-extensions, lens
+     , mcmc-types, mighty-metropolis, mwc-probability, pipes, primitive
      , speedy-slice, transformers
      }:
      mkDerivation {
        pname = "declarative";
-       version = "0.4.0";
-       sha256 = "e771c452cbc7f91b67d078a87349de36182fc5e25a9185f18cff7346941c713c";
+       version = "0.5.1";
+       sha256 = "4ed591067e741682da3f319284dbf1d77c70bdf9d5c78e32575d5018d3f4c624";
        libraryHaskellDepends = [
-         base hasty-hamiltonian lens mcmc-types mighty-metropolis
-         mwc-probability pipes primitive speedy-slice transformers
+         base hasty-hamiltonian kan-extensions lens mcmc-types
+         mighty-metropolis mwc-probability pipes primitive speedy-slice
+         transformers
        ];
        testHaskellDepends = [ base mwc-probability ];
        homepage = "http://github.com/jtobin/declarative";
@@ -52504,6 +52628,19 @@ self: {
        license = "unknown";
      }) {};
 
+  "dependent-map_0_2_4_0" = callPackage
+    ({ mkDerivation, base, containers, dependent-sum }:
+     mkDerivation {
+       pname = "dependent-map";
+       version = "0.2.4.0";
+       sha256 = "5db396bdb5d156434af920c074316c3b84b4d39ba8e1cd349c7bb6679cb28246";
+       libraryHaskellDepends = [ base containers dependent-sum ];
+       homepage = "https://github.com/mokus0/dependent-map";
+       description = "Dependent finite maps (partial dependent products)";
+       license = "unknown";
+       hydraPlatforms = stdenv.lib.platforms.none;
+     }) {};
+
   "dependent-state" = callPackage
     ({ mkDerivation, base, lens, mtl, prologue }:
      mkDerivation {
@@ -56151,22 +56288,23 @@ self: {
      }) {};
 
   "dom-parser" = callPackage
-    ({ mkDerivation, base, data-default, hspec, lens, mtl, open-union
-     , semigroups, shakespeare, text, transformers, type-fun
+    ({ mkDerivation, base, containers, data-default, hspec, lens, mtl
+     , open-union, semigroups, shakespeare, text, transformers, type-fun
      , xml-conduit, xml-lens
      }:
      mkDerivation {
        pname = "dom-parser";
-       version = "0.1.1";
-       sha256 = "e001c486adb3b2c6c6ab18e70205dc759ea018b6db084f8668bb424b623e4e03";
+       version = "1.0.0";
+       sha256 = "6d48ca6cd564919af8574cc91c97f050f50747f358e159797895fd0517dc9583";
        libraryHaskellDepends = [
-         base lens mtl open-union semigroups shakespeare text transformers
+         base containers lens mtl open-union semigroups text transformers
          type-fun xml-conduit xml-lens
        ];
        testHaskellDepends = [
          base data-default hspec lens semigroups shakespeare text
          xml-conduit
        ];
+       homepage = "https://github.com/typeable/dom-parser";
        description = "Simple monadic DOM parser";
        license = stdenv.lib.licenses.mit;
      }) {};
@@ -57872,6 +58010,18 @@ self: {
        hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
+  "echo" = callPackage
+    ({ mkDerivation, base, process }:
+     mkDerivation {
+       pname = "echo";
+       version = "0.1";
+       sha256 = "a7211a9da1fa10dc7d95e89d2c68dadf063b3826d81e42eb085df91c46353e4d";
+       libraryHaskellDepends = [ base process ];
+       homepage = "https://github.com/RyanGlScott/echo";
+       description = "A cross-platform, cross-console way to handle echoing terminal input";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
   "ecma262" = callPackage
     ({ mkDerivation, base, containers, data-default, lens, parsec, safe
      , transformers
@@ -58301,20 +58451,20 @@ self: {
 
   "egison" = callPackage
     ({ mkDerivation, array, base, containers, directory, filepath, ghc
-     , ghc-paths, Glob, haskeline, HUnit, mtl, parsec, process, random
-     , regex-tdfa, test-framework, test-framework-hunit, text
-     , transformers, unordered-containers, vector
+     , ghc-paths, Glob, haskeline, HUnit, monad-parallel, mtl, parsec
+     , process, random, regex-tdfa, test-framework, test-framework-hunit
+     , text, transformers, unordered-containers, vector
      }:
      mkDerivation {
        pname = "egison";
-       version = "3.6.3";
-       sha256 = "178eebc1798fb6d1c2fceeb8f68c2b7cd87a25ff35db9274c2115e6b5100e6d5";
+       version = "3.6.4";
+       sha256 = "8900413b3f0e42c0907bec37dfd2ed0d2f6c618836ea6054615a786ff4fcf5f3";
        isLibrary = true;
        isExecutable = true;
        libraryHaskellDepends = [
-         array base containers directory ghc ghc-paths haskeline mtl parsec
-         process random regex-tdfa text transformers unordered-containers
-         vector
+         array base containers directory ghc ghc-paths haskeline
+         monad-parallel mtl parsec process random regex-tdfa text
+         transformers unordered-containers vector
        ];
        executableHaskellDepends = [
          array base containers directory filepath ghc ghc-paths haskeline
@@ -62897,6 +63047,27 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
+  "feed_0_3_12_0" = callPackage
+    ({ mkDerivation, base, HUnit, old-locale, old-time, test-framework
+     , test-framework-hunit, time, time-locale-compat, utf8-string, xml
+     }:
+     mkDerivation {
+       pname = "feed";
+       version = "0.3.12.0";
+       sha256 = "cc2d6a3b91027d75b91a0a4c0f83f2df68bee3ce0d7338ea5ae0bcab6dd47942";
+       libraryHaskellDepends = [
+         base old-locale old-time time time-locale-compat utf8-string xml
+       ];
+       testHaskellDepends = [
+         base HUnit old-locale old-time test-framework test-framework-hunit
+         time time-locale-compat utf8-string xml
+       ];
+       homepage = "https://github.com/bergmark/feed";
+       description = "Interfacing with RSS (v 0.9x, 2.x, 1.0) + Atom feeds.";
+       license = stdenv.lib.licenses.bsd3;
+       hydraPlatforms = stdenv.lib.platforms.none;
+     }) {};
+
   "feed-cli" = callPackage
     ({ mkDerivation, base, directory, feed, old-locale, old-time, time
      , xml
@@ -64354,6 +64525,27 @@ self: {
        license = stdenv.lib.licenses.lgpl21;
      }) {};
 
+  "fixie" = callPackage
+    ({ mkDerivation, base, containers, data-default-class, either
+     , haskell-src-exts, haskell-src-meta, hspec, hspec-discover, mtl
+     , template-haskell, text, th-orphans, transformers
+     }:
+     mkDerivation {
+       pname = "fixie";
+       version = "1.0.0";
+       sha256 = "b016c231a391816d4dca407f06e64b87d1c29b55fddcae9e0fc28df942bc4f6d";
+       libraryHaskellDepends = [
+         base containers data-default-class either haskell-src-exts
+         haskell-src-meta mtl template-haskell text th-orphans
+       ];
+       testHaskellDepends = [
+         base hspec hspec-discover mtl template-haskell transformers
+       ];
+       homepage = "http://github.com/jxv/fixie#readme";
+       description = "Opininated testing framework for mtl style (spies, stubs, and mocks)";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
   "fixplate" = callPackage
     ({ mkDerivation, base, containers, QuickCheck, tasty
      , tasty-quickcheck
@@ -69483,8 +69675,8 @@ self: {
      }:
      mkDerivation {
        pname = "ghc-prof";
-       version = "1.0.1";
-       sha256 = "3949eb1542f92ed99b38d4f2eb3efb6161fe3250a778b71e638af52463c23de4";
+       version = "1.2.0";
+       sha256 = "fcc0d06e75b6b753b9edec96cda46a4b67138a7ddd489da55dd351f475c08810";
        libraryHaskellDepends = [
          attoparsec base containers scientific text time
        ];
@@ -71421,6 +71613,7 @@ self: {
        homepage = "https://github.com/ElastiLotem/git-mediate";
        description = "Remove trivial conflict markers in a git repository";
        license = stdenv.lib.licenses.gpl2;
+       hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
   "git-monitor" = callPackage
@@ -73985,6 +74178,8 @@ self: {
        pname = "gogol-core";
        version = "0.1.1";
        sha256 = "8f6c7dee658281c5d006c5ec4b475665544989c4d9141737e040857e15f3d483";
+       revision = "1";
+       editedCabalFile = "54bcd3f073a1f1d76726446c4efb96c8b573c3020ffbf6296313c9f6f76d1436";
        libraryHaskellDepends = [
          aeson attoparsec base bifunctors bytestring case-insensitive
          conduit dlist exceptions hashable http-api-data http-client
@@ -79211,6 +79406,8 @@ self: {
        pname = "hackage-security";
        version = "0.5.2.2";
        sha256 = "507a837851264a774c8f4d400f798c3dac5be11dc428fe72d33ef594ca533c41";
+       revision = "1";
+       editedCabalFile = "abb26d1da6e07e187a4494591154080415152787c2583c09acf522ab929b9642";
        libraryHaskellDepends = [
          base base16-bytestring base64-bytestring bytestring Cabal
          containers cryptohash-sha256 directory ed25519 filepath ghc-prim
@@ -85213,8 +85410,8 @@ self: {
      }:
      mkDerivation {
        pname = "hasql-optparse-applicative";
-       version = "0.2";
-       sha256 = "c006e033547c82b4986e8bbc09997f73bb5bb75a7e08e10fb29ba06117aaa42b";
+       version = "0.2.1";
+       sha256 = "170d8a1322866f048d5d05c19cd04f881bbaee0dc4a06a3503280c7a8491d5ea";
        libraryHaskellDepends = [
          base-prelude hasql hasql-pool optparse-applicative
        ];
@@ -85486,16 +85683,17 @@ self: {
        license = stdenv.lib.licenses.mit;
      }) {};
 
-  "hasty-hamiltonian_1_2_0" = callPackage
-    ({ mkDerivation, ad, base, lens, mcmc-types, mwc-probability, pipes
-     , primitive, transformers
+  "hasty-hamiltonian_1_3_0" = callPackage
+    ({ mkDerivation, ad, base, kan-extensions, lens, mcmc-types
+     , mwc-probability, pipes, primitive, transformers
      }:
      mkDerivation {
        pname = "hasty-hamiltonian";
-       version = "1.2.0";
-       sha256 = "602e6bff253cae2151b6c4eb8c81a19dc0a2525bf63bdbd5b12396358548cdda";
+       version = "1.3.0";
+       sha256 = "15f713bc72cda97a5efad2c75d38915f3b765966142710f069db72ff49eefb31";
        libraryHaskellDepends = [
-         base lens mcmc-types mwc-probability pipes primitive transformers
+         base kan-extensions lens mcmc-types mwc-probability pipes primitive
+         transformers
        ];
        testHaskellDepends = [ ad base mwc-probability ];
        homepage = "http://github.com/jtobin/hasty-hamiltonian";
@@ -86478,6 +86676,27 @@ self: {
        license = stdenv.lib.licenses.mit;
      }) {};
 
+  "hdevtools_0_1_5_0" = callPackage
+    ({ mkDerivation, base, Cabal, cmdargs, directory, filepath, ghc
+     , ghc-boot, ghc-paths, network, process, syb, time, transformers
+     , unix
+     }:
+     mkDerivation {
+       pname = "hdevtools";
+       version = "0.1.5.0";
+       sha256 = "ed81236f3809a367c5f4401905ae283f8de92cd5b26c0b8370586ab7690d04e7";
+       isLibrary = false;
+       isExecutable = true;
+       executableHaskellDepends = [
+         base Cabal cmdargs directory filepath ghc ghc-boot ghc-paths
+         network process syb time transformers unix
+       ];
+       homepage = "https://github.com/hdevtools/hdevtools/";
+       description = "Persistent GHC powered background server for FAST haskell development tools";
+       license = stdenv.lib.licenses.mit;
+       hydraPlatforms = stdenv.lib.platforms.none;
+     }) {};
+
   "hdf" = callPackage
     ({ mkDerivation, base, directory, fgl, fgl-visualize, filepath
      , hosc, hsc3, murmur-hash, process, split, transformers
@@ -87836,8 +88055,8 @@ self: {
     ({ mkDerivation, base, bytestring, extra }:
      mkDerivation {
        pname = "hexml";
-       version = "0.2";
-       sha256 = "4c14883bc7fd5e059e05a24d5daabacec295ee71fcf91e3fdd066e7993085a2a";
+       version = "0.3";
+       sha256 = "ace36d4b3a6ca44dad0b4c2f1ab008252acd281e4ff97c3b08c9af41cafb7386";
        libraryHaskellDepends = [ base bytestring extra ];
        testHaskellDepends = [ base bytestring ];
        homepage = "https://github.com/ndmitchell/hexml#readme";
@@ -101003,8 +101222,8 @@ self: {
      }:
      mkDerivation {
        pname = "ideas";
-       version = "1.5";
-       sha256 = "81969d35319518e7c06d67fea99d106c5a8d86d61b889d64414476327fc95e84";
+       version = "1.6";
+       sha256 = "dea77dafcb95fb2cfab6218bb0b242829c6c90a540da33fd082967cda84a8476";
        libraryHaskellDepends = [
          base cgi containers Diff directory filepath parsec QuickCheck
          random time uniplate wl-pprint
@@ -102470,6 +102689,20 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
+  "indents_0_4_0_0" = callPackage
+    ({ mkDerivation, base, mtl, parsec, tasty, tasty-hunit }:
+     mkDerivation {
+       pname = "indents";
+       version = "0.4.0.0";
+       sha256 = "9478d3f8ea4dd412ffc56225c4727f295b81daffba408bf1e757b4b23859d495";
+       libraryHaskellDepends = [ base mtl parsec ];
+       testHaskellDepends = [ base mtl parsec tasty tasty-hunit ];
+       homepage = "http://github.com/jaspervdj/indents";
+       description = "indentation sensitive parser-combinators for parsec";
+       license = stdenv.lib.licenses.bsd3;
+       hydraPlatforms = stdenv.lib.platforms.none;
+     }) {};
+
   "index-core" = callPackage
     ({ mkDerivation, base }:
      mkDerivation {
@@ -105817,8 +106050,8 @@ self: {
      }:
      mkDerivation {
        pname = "jni";
-       version = "0.1";
-       sha256 = "1e9545909b89552fb3c65ae6454a40912bf31f2a66fe0d3dcbadfc2af21c255b";
+       version = "0.2";
+       sha256 = "f98f57417cc015219446f2439c543dc0accd45a4bfdd87004c4c5be1b0b862bf";
        libraryHaskellDepends = [
          base bytestring containers inline-c singletons thread-local-storage
        ];
@@ -106165,8 +106398,8 @@ self: {
     ({ mkDerivation, aeson, base, bytestring, jsaddle }:
      mkDerivation {
        pname = "jsaddle-wkwebview";
-       version = "0.8.0.0";
-       sha256 = "8770e3f9a452502d62025a142aaabc95ac759625fd56f4600217fc8d9ac69dd1";
+       version = "0.8.1.0";
+       sha256 = "10371cdff510c0229a34def4038e9d8e9e796d0a891b2a424b0e8a05b481d3a0";
        libraryHaskellDepends = [ aeson base bytestring jsaddle ];
        description = "Interface for JavaScript that works with GHCJS and GHC";
        license = stdenv.lib.licenses.mit;
@@ -107474,10 +107707,8 @@ self: {
      }:
      mkDerivation {
        pname = "kansas-lava";
-       version = "0.2.4.3";
-       sha256 = "3bf057340e4a1953e2eef099e26215cd99d4c595feab82cc43c6be1cbf2c5344";
-       revision = "1";
-       editedCabalFile = "7b1860125ab2958d3831cb2536a6b939879f09951199649182bb848e70b583eb";
+       version = "0.2.4.4";
+       sha256 = "ed44a01f95c72580c3e198ea43f42a582ec44bbdc8897629fe37f874208f6c5d";
        libraryHaskellDepends = [
          base bytestring cmdargs containers data-default data-reify
          directory dotgen filepath netlist netlist-to-vhdl process random
@@ -108786,8 +109017,8 @@ self: {
      }:
      mkDerivation {
        pname = "krapsh";
-       version = "0.1.6.0";
-       sha256 = "12c4c3a9d4e0d013056ad269a51ae77078a6a582b9b5924d5e58b73251176d6e";
+       version = "0.1.6.2";
+       sha256 = "081bebfed17c6bd548c0a3ef69523bad78eb0aa11e17d5ceb0de7baebc24cc9b";
        libraryHaskellDepends = [
          aeson aeson-pretty base base16-bytestring binary bytestring
          containers cryptohash-sha256 deepseq exceptions formatting hashable
@@ -109685,8 +109916,8 @@ self: {
      }:
      mkDerivation {
        pname = "lambdacube-gl";
-       version = "0.5.1.2";
-       sha256 = "2b71bfd829096f8ac59f4e37ebdf6d8bdc4c84bdfaa6cd2c83d5e41fd05ef9fe";
+       version = "0.5.2.0";
+       sha256 = "6552d8dc5aa3d1639155d42890934aeaa19afe6c5feafee041199ad98cfbd165";
        libraryHaskellDepends = [
          base bytestring containers JuicyPixels lambdacube-ir mtl OpenGLRaw
          vector vector-algorithms
@@ -111718,8 +111949,8 @@ self: {
        pname = "lens";
        version = "4.15.1";
        sha256 = "5cfaa64cb1b9787193c2247a1ed1c248104ba5fadb91cec6432e648e41b1bea6";
-       revision = "2";
-       editedCabalFile = "012be5e38b4fa0f4cb98ad04d6eb82a48eea6d789213a058b08fdc2e64aa1327";
+       revision = "3";
+       editedCabalFile = "d23792e0e14306446fe13c8de692b46cbf0aedd22ea22248d70c9dc71646716f";
        libraryHaskellDepends = [
          array base base-orphans bifunctors bytestring comonad containers
          contravariant distributive exceptions filepath free ghc-prim
@@ -112012,22 +112243,23 @@ self: {
     ({ mkDerivation, ansi-wl-pprint, base, csv, directory, filemanip
      , filepath, hspec, natural-sort, optparse-applicative, parsec
      , pipes, regex-tdfa, semigroups, terminal-progress-bar, text
+     , transformers
      }:
      mkDerivation {
        pname = "lentil";
-       version = "1.0.3.2";
-       sha256 = "7c4fcfd08e2b4369f14a3502215cdb6f70a8f776350a6113d3d6f8dbc7a1c397";
+       version = "1.0.4.0";
+       sha256 = "e990aad8168d8e106ef35a0e8dc1fc707d467dfd87db8127f8ec568a47100f8b";
        isLibrary = false;
        isExecutable = true;
        executableHaskellDepends = [
          ansi-wl-pprint base csv directory filemanip filepath natural-sort
          optparse-applicative parsec pipes regex-tdfa semigroups
-         terminal-progress-bar text
+         terminal-progress-bar text transformers
        ];
        testHaskellDepends = [
          ansi-wl-pprint base csv directory filemanip filepath hspec
          natural-sort optparse-applicative parsec pipes regex-tdfa
-         semigroups terminal-progress-bar text
+         semigroups terminal-progress-bar text transformers
        ];
        homepage = "http://www.ariis.it/static/articles/lentil/page.html";
        description = "frugal issue tracker";
@@ -115459,6 +115691,25 @@ self: {
        hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
+  "logger-thread" = callPackage
+    ({ mkDerivation, base, fast-logger, protolude, safe-exceptions, stm
+     , text, time
+     }:
+     mkDerivation {
+       pname = "logger-thread";
+       version = "0.1.0.2";
+       sha256 = "ac0a54001a69cff6f975209c4d9d399fb58ef59bb0ad6ac742c5ffedeac04a2a";
+       isLibrary = true;
+       isExecutable = true;
+       libraryHaskellDepends = [
+         base fast-logger protolude safe-exceptions stm text time
+       ];
+       executableHaskellDepends = [ base protolude stm ];
+       homepage = "https://github.com/joe9/logger-thread#readme";
+       description = "Run FastLogger in a thread and direct all queued messages to it";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
   "logging" = callPackage
     ({ mkDerivation, base, binary, bytestring, fast-logger, hspec
      , lifted-base, monad-control, old-locale, regex-compat, text, time
@@ -116696,8 +116947,8 @@ self: {
      }:
      mkDerivation {
        pname = "lzma-conduit";
-       version = "1.1.3.0";
-       sha256 = "abf9e7a052a2bbd85923237a6fa7a73e7e077b20908ad3d68e6c24285aef390f";
+       version = "1.1.3.1";
+       sha256 = "2c181aece2c81c9408271e805a00f2833c5ca79f2c7cb55e3a8b6cb0388d612d";
        libraryHaskellDepends = [
          base bindings-DSL bytestring conduit resourcet transformers
        ];
@@ -116839,6 +117090,7 @@ self: {
        homepage = "http://github.com/as-capabl/machinecell";
        description = "Arrow based stream transducers";
        license = stdenv.lib.licenses.bsd3;
+       hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
   "machines" = callPackage
@@ -120210,16 +120462,17 @@ self: {
        license = stdenv.lib.licenses.mit;
      }) {};
 
-  "mighty-metropolis_1_1_0" = callPackage
-    ({ mkDerivation, base, containers, mcmc-types, mwc-probability
-     , pipes, primitive, transformers
+  "mighty-metropolis_1_2_0" = callPackage
+    ({ mkDerivation, base, containers, kan-extensions, mcmc-types
+     , mwc-probability, pipes, primitive, transformers
      }:
      mkDerivation {
        pname = "mighty-metropolis";
-       version = "1.1.0";
-       sha256 = "2a8ac91fe51fa440347ce41edafca463fbf0d822fffca89796250e5e79143f6b";
+       version = "1.2.0";
+       sha256 = "8d3c0b4b65024846291c4f547c45e5c04f587aefd0e8d041d54679bb519871c0";
        libraryHaskellDepends = [
-         base mcmc-types mwc-probability pipes primitive transformers
+         base kan-extensions mcmc-types mwc-probability pipes primitive
+         transformers
        ];
        testHaskellDepends = [ base containers mwc-probability ];
        homepage = "http://github.com/jtobin/mighty-metropolis";
@@ -127530,6 +127783,7 @@ self: {
        homepage = "https://github.com/centromere/nfc#readme";
        description = "libnfc bindings";
        license = stdenv.lib.licenses.publicDomain;
+       hydraPlatforms = stdenv.lib.platforms.none;
      }) {nfc = null;};
 
   "ngrams-loader" = callPackage
@@ -131035,6 +131289,19 @@ self: {
        license = "unknown";
      }) {};
 
+  "ordered-containers" = callPackage
+    ({ mkDerivation, base, containers }:
+     mkDerivation {
+       pname = "ordered-containers";
+       version = "0.0";
+       sha256 = "ea40528ec95f2424bd7231da44b9d96a80b46b4116b2cdfbb57269c88f2419cb";
+       revision = "1";
+       editedCabalFile = "a8de69537c43ab967f7f512466a5a0e32000e9179239b4c10adf3cd3cfd1e524";
+       libraryHaskellDepends = [ base containers ];
+       description = "Set- and Map-like types that remember the order elements were inserted";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
   "orders" = callPackage
     ({ mkDerivation, base, containers }:
      mkDerivation {
@@ -131821,6 +132088,8 @@ self: {
        pname = "pandoc";
        version = "1.19.1";
        sha256 = "9d22db0a1536de0984f4a605f1a28649e68d540e6d892947d9644987ecc4172a";
+       revision = "1";
+       editedCabalFile = "6db38c75bdb36377e1424b91b2662205dbe54152995a08ab83127bfb17ee027b";
        configureFlags = [ "-fhttps" "-f-trypandoc" ];
        isLibrary = true;
        isExecutable = true;
@@ -131891,8 +132160,8 @@ self: {
      }:
      mkDerivation {
        pname = "pandoc-citeproc-preamble";
-       version = "1.2.1";
-       sha256 = "99e0988741a8b820ca951b2aabc35d251119c84e0a8245bf0c9b55cbe0e22121";
+       version = "1.2.2";
+       sha256 = "ee496f052eea0ad9a881d8056025f04cd83ec9773d695e15220151c33890579c";
        isLibrary = false;
        isExecutable = true;
        executableHaskellDepends = [
@@ -133738,6 +134007,50 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
+  "pdf-slave" = callPackage
+    ({ mkDerivation, aeson, base, base64-bytestring, bytestring
+     , containers, exceptions, haskintex, HaTeX, optparse-applicative
+     , pdf-slave-template, shelly, system-filepath, text
+     , unordered-containers, yaml
+     }:
+     mkDerivation {
+       pname = "pdf-slave";
+       version = "1.2.0.0";
+       sha256 = "bf45cd593271427ab6f72dffaa1e355a33b59ab20d18a34590a3a1c50d5fe029";
+       revision = "1";
+       editedCabalFile = "cf72f50463292710ceb929edc7cb9e61c41c5da36676e5d0cc7e7cc5d0dd23a4";
+       isLibrary = true;
+       isExecutable = true;
+       libraryHaskellDepends = [
+         aeson base base64-bytestring bytestring containers exceptions
+         haskintex HaTeX pdf-slave-template shelly system-filepath
+         unordered-containers yaml
+       ];
+       executableHaskellDepends = [
+         aeson base bytestring optparse-applicative pdf-slave-template
+         shelly system-filepath text yaml
+       ];
+       homepage = "https://github.com/NCrashed/pdf-slave#readme";
+       description = "Tool to generate PDF from haskintex templates and YAML input";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
+  "pdf-slave-template" = callPackage
+    ({ mkDerivation, aeson, base, base64-bytestring, bytestring
+     , containers, text
+     }:
+     mkDerivation {
+       pname = "pdf-slave-template";
+       version = "1.2.0.0";
+       sha256 = "63acbe9eb391f698d8428f40cffcf8f3a2f483cd460c8c45d50e297a11b92531";
+       libraryHaskellDepends = [
+         aeson base base64-bytestring bytestring containers text
+       ];
+       homepage = "https://github.com/ncrashed/pdf-slave#readme";
+       description = "Template format definition for pdf-slave tool";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
   "pdf-toolbox-content" = callPackage
     ({ mkDerivation, attoparsec, base, base16-bytestring, bytestring
      , containers, io-streams, pdf-toolbox-core, text
@@ -136949,6 +137262,26 @@ self: {
        hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
+  "plan-applicative" = callPackage
+    ({ mkDerivation, base, bifunctors, comonad, containers, doctest
+     , profunctors, streaming, tasty, tasty-hunit, transformers
+     }:
+     mkDerivation {
+       pname = "plan-applicative";
+       version = "1.0.0.0";
+       sha256 = "911a0d6f69d2dd4c7642abc855c153d90f799035a722324965506ecb2f954dd7";
+       libraryHaskellDepends = [
+         base bifunctors comonad containers profunctors streaming
+         transformers
+       ];
+       testHaskellDepends = [
+         base bifunctors comonad containers doctest profunctors streaming
+         tasty tasty-hunit transformers
+       ];
+       description = "Applicative/Arrow for resource estimation and progress tracking";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
   "plan-b" = callPackage
     ({ mkDerivation, base, exceptions, hspec, path, path-io
      , transformers
@@ -137314,8 +137647,8 @@ self: {
      }:
      mkDerivation {
        pname = "ply-loader";
-       version = "0.4.2";
-       sha256 = "60adbcb9323fd221b70ed106b9c418636112e989b3364a2eb0227fefce47afaf";
+       version = "0.5.0";
+       sha256 = "70f93a7043531b095f2762fe819ae2ae26a1913c071f179f3e4e936d9223db6f";
        isLibrary = true;
        isExecutable = true;
        libraryHaskellDepends = [
@@ -139146,13 +139479,13 @@ self: {
   "preamble" = callPackage
     ({ mkDerivation, aeson, base, basic-prelude, exceptions
      , fast-logger, lens, monad-control, monad-logger, mtl, resourcet
-     , safe, shake, template-haskell, text, text-manipulate, time
+     , safe, shakers, template-haskell, text, text-manipulate, time
      , transformers-base, unordered-containers
      }:
      mkDerivation {
        pname = "preamble";
-       version = "0.0.3";
-       sha256 = "5a4a1a4fa8dcad02d6afbdc99b44d4f9e94571b48b88115b7d1ebb266f776a73";
+       version = "0.0.8";
+       sha256 = "2827df5cd7df280b1ca9092e0a17b585341f758ec91d490be7287483f623b374";
        isLibrary = true;
        isExecutable = true;
        libraryHaskellDepends = [
@@ -139160,7 +139493,7 @@ self: {
          monad-logger mtl resourcet safe template-haskell text
          text-manipulate time transformers-base unordered-containers
        ];
-       executableHaskellDepends = [ base basic-prelude shake ];
+       executableHaskellDepends = [ base shakers ];
        homepage = "https://github.com/swift-nav/preamble";
        description = "Yet another prelude";
        license = stdenv.lib.licenses.mit;
@@ -139726,8 +140059,8 @@ self: {
      }:
      mkDerivation {
        pname = "pretty-simple";
-       version = "0.2.0.0";
-       sha256 = "f4f9141b0b816ad56918bb92daba2b62295207eb3119afcc3c2baf2ae46bb4d3";
+       version = "0.3.0.0";
+       sha256 = "b34af2742904717e1a46c6aa9816eeffedc4aea67452f61dd98fb06aae1d4f0d";
        libraryHaskellDepends = [
          ansi-terminal base lens mono-traversable mtl parsec semigroups
          transformers
@@ -139736,6 +140069,7 @@ self: {
        homepage = "https://github.com/cdepillabout/pretty-simple";
        description = "Simple pretty printer for any datatype with a 'Show' instance";
        license = stdenv.lib.licenses.bsd3;
+       hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
   "pretty-sop" = callPackage
@@ -142554,19 +142888,22 @@ self: {
 
   "qr-imager" = callPackage
     ({ mkDerivation, aeson, base, bytestring, cryptonite, directory
-     , haskell-qrencode, jose-jwt, JuicyPixels, lens, vector
+     , haskell-qrencode, jose-jwt, JuicyPixels, lens, MissingH
+     , optparse-applicative, process, vector
      }:
      mkDerivation {
        pname = "qr-imager";
-       version = "0.1.0.1";
-       sha256 = "2936851586f3e63e7e4aa589d06d88cb6968f5e2c5861f71df62a89fc43d7ef9";
+       version = "0.1.2.1";
+       sha256 = "72e1c72a7e3da7769401b4d1125b3f527274bdc5f97d78be2e14cf619d705d30";
        isLibrary = true;
        isExecutable = true;
        libraryHaskellDepends = [
          aeson base bytestring cryptonite directory haskell-qrencode
-         jose-jwt JuicyPixels lens vector
+         jose-jwt JuicyPixels lens MissingH optparse-applicative process
+         vector
        ];
-       executableHaskellDepends = [ base bytestring ];
+       executableHaskellDepends = [ base ];
+       testHaskellDepends = [ base process ];
        homepage = "https://github.com/vmchale/QRImager#readme";
        description = "Library to generate QR codes from bytestrings and objects";
        license = stdenv.lib.licenses.bsd3;
@@ -149504,7 +149841,6 @@ self: {
        homepage = "http://github.com/agrafix/rocksdb-haskell";
        description = "Haskell bindings to RocksDB";
        license = stdenv.lib.licenses.bsd3;
-       platforms = [ "x86_64-linux" ];
      }) {inherit (pkgs) rocksdb;};
 
   "roguestar" = callPackage
@@ -153929,8 +154265,8 @@ self: {
      }:
      mkDerivation {
        pname = "serokell-util";
-       version = "0.1.2.3";
-       sha256 = "f30880e753f8c7e258906ab0a83f15f23b4ae90cd3bbba02719556421dc97f0a";
+       version = "0.1.3.0";
+       sha256 = "ddf321ba0126fde5757f186c5080f3a7ffb7539582040aab263165f83cafcc78";
        libraryHaskellDepends = [
          acid-state aeson aeson-extra base base16-bytestring
          base64-bytestring binary binary-orphans bytestring cereal
@@ -154184,7 +154520,7 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
-  "servant-auth-cookie_0_4" = callPackage
+  "servant-auth-cookie_0_4_2" = callPackage
     ({ mkDerivation, base, base-compat, base64-bytestring
      , blaze-builder, blaze-html, blaze-markup, bytestring, cereal
      , cookie, cryptonite, data-default, deepseq, exceptions, hspec
@@ -154194,8 +154530,8 @@ self: {
      }:
      mkDerivation {
        pname = "servant-auth-cookie";
-       version = "0.4";
-       sha256 = "2b5144612cbf8835b5f069f885d9f32483a63884d5d008c7110dd9273756eef1";
+       version = "0.4.2";
+       sha256 = "e1199517da33d5f0b3735567d2391dcf36ca8ca61edea703b674103192a1ed79";
        libraryHaskellDepends = [
          base base64-bytestring blaze-builder bytestring cereal cookie
          cryptonite data-default exceptions http-api-data http-types memory
@@ -156169,6 +156505,21 @@ self: {
        hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
+  "shakers" = callPackage
+    ({ mkDerivation, base, basic-prelude, directory, shake }:
+     mkDerivation {
+       pname = "shakers";
+       version = "0.0.4";
+       sha256 = "b2769d6b01eab98de11c3c072a2cbc2a5706e0dfdcaf916b67fc344d49f1e09f";
+       isLibrary = true;
+       isExecutable = true;
+       libraryHaskellDepends = [ base basic-prelude directory shake ];
+       executableHaskellDepends = [ base ];
+       homepage = "https://github.com/swift-nav/shakers";
+       description = "Shake helpers";
+       license = stdenv.lib.licenses.mit;
+     }) {};
+
   "shakespeare" = callPackage
     ({ mkDerivation, aeson, base, blaze-html, blaze-markup, bytestring
      , containers, directory, exceptions, ghc-prim, hspec, HUnit, parsec
@@ -158417,6 +158768,29 @@ self: {
        license = stdenv.lib.licenses.mit;
      }) {};
 
+  "skylighting" = callPackage
+    ({ mkDerivation, aeson, base, blaze-html, bytestring
+     , case-insensitive, containers, Diff, directory, filepath, HUnit
+     , hxt, mtl, pretty-show, QuickCheck, regex-pcre-builtin, safe
+     , tasty, tasty-golden, tasty-hunit, text, utf8-string
+     }:
+     mkDerivation {
+       pname = "skylighting";
+       version = "0.1.0.1";
+       sha256 = "e7cdbea2909306f97135b4444489cfff0136ec5609c22228a68201440d6304ac";
+       libraryHaskellDepends = [
+         aeson base blaze-html bytestring case-insensitive containers
+         directory filepath hxt mtl regex-pcre-builtin safe text utf8-string
+       ];
+       testHaskellDepends = [
+         aeson base bytestring Diff directory filepath HUnit pretty-show
+         QuickCheck tasty tasty-golden tasty-hunit text
+       ];
+       homepage = "https://github.com/jgm/skylighting";
+       description = "syntax highlighting library";
+       license = stdenv.lib.licenses.gpl2;
+     }) {};
+
   "skype4hs" = callPackage
     ({ mkDerivation, attoparsec, base, bytestring, lifted-base
      , monad-control, mtl, stm, text, time, transformers-base, word8
@@ -161635,16 +162009,17 @@ self: {
        license = stdenv.lib.licenses.mit;
      }) {};
 
-  "speedy-slice_0_2_0" = callPackage
-    ({ mkDerivation, base, containers, lens, mcmc-types
+  "speedy-slice_0_3_0" = callPackage
+    ({ mkDerivation, base, containers, kan-extensions, lens, mcmc-types
      , mwc-probability, pipes, primitive, transformers
      }:
      mkDerivation {
        pname = "speedy-slice";
-       version = "0.2.0";
-       sha256 = "9ae1b3241624bfb5e656347cca1f598ae9b67b1abe23b00ddf8d3d5925234963";
+       version = "0.3.0";
+       sha256 = "efbf8a10b681b940078f70fb9aca43fec8ba436c82f3faf719bbe495ba152899";
        libraryHaskellDepends = [
-         base lens mcmc-types mwc-probability pipes primitive transformers
+         base kan-extensions lens mcmc-types mwc-probability pipes primitive
+         transformers
        ];
        testHaskellDepends = [ base containers mwc-probability ];
        homepage = "http://github.com/jtobin/speedy-slice";
@@ -163306,6 +163681,18 @@ self: {
        license = stdenv.lib.licenses.mit;
      }) {};
 
+  "staf" = callPackage
+    ({ mkDerivation, base }:
+     mkDerivation {
+       pname = "staf";
+       version = "0.1.0.0";
+       sha256 = "ce066d4b64771489176e72f081b8ec5ba62237ff1f12abe5f515884b0ce8a925";
+       libraryHaskellDepends = [ base ];
+       homepage = "https://github.com/lovasko/staf";
+       description = "Numerical statistics for Foldable containers";
+       license = "unknown";
+     }) {};
+
   "standalone-derive-topdown" = callPackage
     ({ mkDerivation, base, mtl, template-haskell }:
      mkDerivation {
@@ -165833,6 +166220,24 @@ self: {
        hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
+  "styx" = callPackage
+    ({ mkDerivation, aeson, base, containers, directory, filepath, mtl
+     , optparse-applicative, process, text, yaml
+     }:
+     mkDerivation {
+       pname = "styx";
+       version = "1.0";
+       sha256 = "2fc5e840d35663ca10771758dec362017f32611675e44fe2e988dd12a05e293c";
+       isLibrary = false;
+       isExecutable = true;
+       executableHaskellDepends = [
+         aeson base containers directory filepath mtl optparse-applicative
+         process text yaml
+       ];
+       description = "A generator of nix files";
+       license = "GPL";
+     }) {};
+
   "sub-state" = callPackage
     ({ mkDerivation, base, mtl, QuickCheck, quickcheck-instances, sets
      , tasty, tasty-hunit, tasty-quickcheck
@@ -168713,6 +169118,25 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
+  "tasty-ant-xml_1_0_4" = callPackage
+    ({ mkDerivation, base, containers, directory, filepath
+     , generic-deriving, ghc-prim, mtl, stm, tagged, tasty, transformers
+     , xml
+     }:
+     mkDerivation {
+       pname = "tasty-ant-xml";
+       version = "1.0.4";
+       sha256 = "4d91c509e0e80919d96c16eaa3ee11089b7ee7c87fbe59a947d26bf0c5aef188";
+       libraryHaskellDepends = [
+         base containers directory filepath generic-deriving ghc-prim mtl
+         stm tagged tasty transformers xml
+       ];
+       homepage = "http://github.com/ocharles/tasty-ant-xml";
+       description = "Render tasty output to XML for Jenkins";
+       license = stdenv.lib.licenses.bsd3;
+       hydraPlatforms = stdenv.lib.platforms.none;
+     }) {};
+
   "tasty-dejafu" = callPackage
     ({ mkDerivation, base, dejafu, tagged, tasty }:
      mkDerivation {
@@ -170739,6 +171163,29 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
+  "text-generic-pretty" = callPackage
+    ({ mkDerivation, base, containers, ghc-prim, groom, ixset-typed
+     , protolude, QuickCheck, string-conversions, tasty, tasty-hunit
+     , tasty-quickcheck, text, time, unordered-containers
+     , wl-pprint-text
+     }:
+     mkDerivation {
+       pname = "text-generic-pretty";
+       version = "1.2.1";
+       sha256 = "cff331fdea2f695cf9a2583f4bd7393935b4a6ffa2bd47eb7dd983c6184752c7";
+       libraryHaskellDepends = [
+         base containers ghc-prim groom ixset-typed protolude QuickCheck
+         string-conversions text time unordered-containers wl-pprint-text
+       ];
+       testHaskellDepends = [
+         base containers protolude QuickCheck string-conversions tasty
+         tasty-hunit tasty-quickcheck time unordered-containers
+       ];
+       homepage = "https://github.com/joe9/GenericPretty";
+       description = "A generic, derivable, haskell pretty printer";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
   "text-icu" = callPackage
     ({ mkDerivation, array, base, bytestring, deepseq, directory
      , ghc-prim, HUnit, icu, QuickCheck, random, test-framework
@@ -170781,6 +171228,7 @@ self: {
        homepage = "https://www.lambdanow.us/browser/text-icu-normalized";
        description = "Dealing with Strict Text in NFC normalization";
        license = stdenv.lib.licenses.gpl3;
+       hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
   "text-icu-translit" = callPackage
@@ -173289,8 +173737,8 @@ self: {
      }:
      mkDerivation {
        pname = "timeseries";
-       version = "0.3.0";
-       sha256 = "0e59e55b0c1346593f752d88fa69ea9c35fb2942ef13f984727a26ede69d1896";
+       version = "0.4.0";
+       sha256 = "a073a252dcdb671e57a784f4b37f2009f6e0890579bf705869c572923047af51";
        libraryHaskellDepends = [
          base bytestring cassava statistics text text-time time vector
        ];
@@ -177358,23 +177806,24 @@ self: {
   "uhc-light" = callPackage
     ({ mkDerivation, array, base, binary, bytestring, containers
      , directory, fgl, filepath, hashable, mtl, network, old-locale
-     , primitive, process, syb, transformers, uhc-util, uulib, vector
+     , primitive, process, syb, transformers, uhc-util, utf8-string
+     , uulib, vector
      }:
      mkDerivation {
        pname = "uhc-light";
-       version = "1.1.9.4";
-       sha256 = "617fd803d9693cc9c03f071045a892b5a1f8b4564e7764c595014a440261f053";
+       version = "1.1.9.5";
+       sha256 = "eabaf3cdac62afb5c8d37f8ceb0997fd85647493d2d4cc1b0d00d954d586681d";
        isLibrary = true;
        isExecutable = true;
        libraryHaskellDepends = [
          array base binary bytestring containers directory fgl filepath
          hashable mtl network old-locale primitive process syb transformers
-         uhc-util uulib vector
+         uhc-util utf8-string uulib vector
        ];
        executableHaskellDepends = [
          array base binary bytestring containers directory fgl filepath
          hashable mtl network old-locale primitive process syb transformers
-         uhc-util uulib vector
+         uhc-util utf8-string uulib vector
        ];
        homepage = "https://github.com/UU-ComputerScience/uhc";
        description = "Part of UHC packaged as cabal/hackage installable library";
@@ -177389,8 +177838,8 @@ self: {
      }:
      mkDerivation {
        pname = "uhc-util";
-       version = "0.1.6.6";
-       sha256 = "b5abc07215168b1f203ce50da8f13b8170269a5e4b2e4c8a872819f13f14bb47";
+       version = "0.1.6.7";
+       sha256 = "d44b27175e9ce45a15c19c2f589772f4b66ca297a28b34b0ac462a7f6e4f4a75";
        libraryHaskellDepends = [
          array base binary bytestring containers directory fclabels fgl
          hashable logict-state mtl pqueue process time time-compat
@@ -178641,6 +179090,26 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};
 
+  "unordered-containers_0_2_7_2" = callPackage
+    ({ mkDerivation, base, ChasingBottoms, containers, deepseq
+     , hashable, HUnit, QuickCheck, test-framework, test-framework-hunit
+     , test-framework-quickcheck2
+     }:
+     mkDerivation {
+       pname = "unordered-containers";
+       version = "0.2.7.2";
+       sha256 = "7f5c4344fcab01f6046378c64522f0dfd69e417f6c1a8858a24bdabaadb3e56e";
+       libraryHaskellDepends = [ base deepseq hashable ];
+       testHaskellDepends = [
+         base ChasingBottoms containers hashable HUnit QuickCheck
+         test-framework test-framework-hunit test-framework-quickcheck2
+       ];
+       homepage = "https://github.com/tibbe/unordered-containers";
+       description = "Efficient hashing-based container types";
+       license = stdenv.lib.licenses.bsd3;
+       hydraPlatforms = stdenv.lib.platforms.none;
+     }) {};
+
   "unordered-containers-rematch" = callPackage
     ({ mkDerivation, base, hashable, hspec, HUnit, rematch
      , unordered-containers
@@ -183515,8 +183984,8 @@ self: {
      }:
      mkDerivation {
        pname = "wave";
-       version = "0.1.0";
-       sha256 = "93c38138c1e85124544eadf0d381ce4ce0505a441060d226e8f09baddc4c5915";
+       version = "0.1.1";
+       sha256 = "13d5475356efc3ae95c971e930d5e4bf18f9395dc1bd7b63e8bb8e7ed26ddf23";
        libraryHaskellDepends = [
          base bytestring cereal containers data-default-class transformers
        ];
@@ -183926,8 +184395,8 @@ self: {
      }:
      mkDerivation {
        pname = "web3";
-       version = "0.3.4.0";
-       sha256 = "64218b2f2f2319fe137834bbb012e948444f80f88e3da03ee6ecff06b5ecfe27";
+       version = "0.4.1.0";
+       sha256 = "ead3b350b138946ec921c1e1c13ae6bf52f2ba89e7626ba79a562a5bef63faac";
        libraryHaskellDepends = [
          aeson attoparsec base base16-bytestring bytestring cryptonite
          data-default-class http-client memory mtl template-haskell text
@@ -185268,38 +185737,24 @@ self: {
 
   "wolf" = callPackage
     ({ mkDerivation, aeson, amazonka, amazonka-core, amazonka-s3
-     , amazonka-swf, async, base, basic-prelude, bytestring, conduit
-     , conduit-combinators, conduit-extra, directory, exceptions
-     , fast-logger, filemanip, formatting, http-conduit, http-types
-     , lens, lifted-async, lifted-base, monad-control, monad-logger, mtl
-     , mtl-compat, optparse-applicative, optparse-generic, preamble
-     , process, regex-applicative, regex-compat, resourcet, safe, shake
-     , shelly, system-filepath, tasty, tasty-hunit, template-haskell
-     , text, text-manipulate, time, transformers, transformers-base
-     , unordered-containers, uuid, yaml, zlib
+     , amazonka-swf, base, bytestring, conduit, conduit-combinators
+     , conduit-extra, directory, exceptions, filemanip, lifted-async
+     , monad-control, optparse-applicative, optparse-generic, preamble
+     , process, resourcet, shakers, text, time, uuid, yaml
      }:
      mkDerivation {
        pname = "wolf";
-       version = "0.3.1";
-       sha256 = "441d7c82cca74e12fd097ebb3b4d5e3c7b2e3dff4145e65e00a9fd9f57ee224b";
+       version = "0.3.3";
+       sha256 = "2982a25dbdb4bcbfe563cc49f1bae58d8b837014ad28365eb09405222165f311";
        isLibrary = true;
        isExecutable = true;
        libraryHaskellDepends = [
          aeson amazonka amazonka-core amazonka-s3 amazonka-swf base
-         basic-prelude bytestring conduit conduit-combinators conduit-extra
-         directory exceptions fast-logger filemanip formatting http-conduit
-         http-types lens lifted-async lifted-base monad-control monad-logger
-         mtl mtl-compat optparse-applicative preamble process
-         regex-applicative regex-compat resourcet safe template-haskell text
-         text-manipulate time transformers transformers-base
-         unordered-containers uuid yaml
+         bytestring conduit conduit-combinators conduit-extra directory
+         exceptions filemanip lifted-async monad-control
+         optparse-applicative preamble process resourcet text time uuid yaml
        ];
-       executableHaskellDepends = [
-         aeson amazonka-core async base basic-prelude bytestring directory
-         optparse-applicative optparse-generic resourcet shake shelly
-         system-filepath text transformers yaml zlib
-       ];
-       testHaskellDepends = [ base basic-prelude tasty tasty-hunit ];
+       executableHaskellDepends = [ base optparse-generic shakers ];
        homepage = "https://github.com/swift-nav/wolf";
        description = "Amazon Simple Workflow Service Wrapper";
        license = stdenv.lib.licenses.mit;
@@ -185992,6 +186447,7 @@ self: {
        libraryHaskellDepends = [ base cubicbezier wx wxcore ];
        description = "Simple zoomable canvas for wxHaskell";
        license = stdenv.lib.licenses.bsd3;
+       hydraPlatforms = stdenv.lib.platforms.none;
      }) {};
 
   "wxc" = callPackage
@@ -188339,8 +188795,8 @@ self: {
      }:
      mkDerivation {
        pname = "yaml-light-lens";
-       version = "0.3.3.2";
-       sha256 = "27380c456128dc72f117febaf3ade7e8c7a916abc3052e5de9d8ffd5ca01df0d";
+       version = "0.3.3.3";
+       sha256 = "788a79a1afd97d9c41010b6240261995da9e80f5674b4e335beec47d225211cf";
        libraryHaskellDepends = [
          base bytestring bytestring-lexing containers lens yaml-light
        ];
@@ -189219,7 +189675,7 @@ self: {
        license = stdenv.lib.licenses.mit;
      }) {};
 
-  "yesod-bin_1_5_0_1" = callPackage
+  "yesod-bin_1_5_1" = callPackage
     ({ mkDerivation, async, attoparsec, base, base64-bytestring
      , blaze-builder, bytestring, Cabal, conduit, conduit-extra
      , containers, data-default-class, deepseq, directory, file-embed
@@ -189233,8 +189689,8 @@ self: {
      }:
      mkDerivation {
        pname = "yesod-bin";
-       version = "1.5.0.1";
-       sha256 = "5530506d1ddbe0b846f538b366645c416322046aa712d866c422e4778829d3e8";
+       version = "1.5.1";
+       sha256 = "034114dade5a23ec39ffeb9f78a04b7bd9fc0b8942b1a11118475e4c594863cd";
        isLibrary = false;
        isExecutable = true;
        executableHaskellDepends = [
diff --git a/pkgs/development/interpreters/python/cpython/2.7/default.nix b/pkgs/development/interpreters/python/cpython/2.7/default.nix
index 4a25382997c3..5842f6fb309a 100644
--- a/pkgs/development/interpreters/python/cpython/2.7/default.nix
+++ b/pkgs/development/interpreters/python/cpython/2.7/default.nix
@@ -28,7 +28,7 @@ with stdenv.lib;
 
 let
   majorVersion = "2.7";
-  minorVersion = "12";
+  minorVersion = "13";
   minorVersionSuffix = "";
   pythonVersion = majorVersion;
   version = "${majorVersion}.${minorVersion}${minorVersionSuffix}";
@@ -37,7 +37,7 @@ let
 
   src = fetchurl {
     url = "https://www.python.org/ftp/python/${majorVersion}.${minorVersion}/Python-${version}.tar.xz";
-    sha256 = "0y7rl603vmwlxm6ilkhc51rx2mfj14ckcz40xxgs0ljnvlhp30yp";
+    sha256 = "0cgpk3zk0fgpji59pb4zy9nzljr70qzgv1vpz5hq5xw2d2c47m9m";
   };
 
   hasDistutilsCxxPatch = !(stdenv.cc.isGNU or false);
@@ -57,13 +57,6 @@ let
 
       ./properly-detect-curses.patch
 
-      # FIXME: get rid of this after the next release, when the commit referenced here makes
-      # it in. We need it until then because it breaks compilation of programs that use
-      # locale with clang 3.8 and higher.
-      (fetchpatch {
-        url    = "https://hg.python.org/cpython/raw-rev/e0ec3471cb09";
-        sha256 = "1jdgb70jw942r4kmr01qll7mk1di8jx0qiabmp20jhnmha246ivq";
-      })
     ] ++ optionals stdenv.isLinux [
 
       # Disable the use of ldconfig in ctypes.util.find_library (since
diff --git a/pkgs/development/interpreters/python/cpython/2.7/no-ldconfig.patch b/pkgs/development/interpreters/python/cpython/2.7/no-ldconfig.patch
index 44c38fb29534..2a6b2a20dd19 100644
--- a/pkgs/development/interpreters/python/cpython/2.7/no-ldconfig.patch
+++ b/pkgs/development/interpreters/python/cpython/2.7/no-ldconfig.patch
@@ -1,8 +1,18 @@
+From 6b0f329a9f37110020ca02b35c8125391ef282b7 Mon Sep 17 00:00:00 2001
+From: Frederik Rietdijk <fridh@fridh.nl>
+Date: Sat, 24 Dec 2016 15:56:10 +0100
+Subject: [PATCH] no ldconfig
+
+---
+ Lib/ctypes/util.py | 35 +----------------------------------
+ Lib/uuid.py        | 47 -----------------------------------------------
+ 2 files changed, 1 insertion(+), 81 deletions(-)
+
 diff --git a/Lib/ctypes/util.py b/Lib/ctypes/util.py
-index b2c514d..a6eca81 100644
+index ab10ec5..f253e34 100644
 --- a/Lib/ctypes/util.py
 +++ b/Lib/ctypes/util.py
-@@ -207,31 +207,7 @@ elif os.name == "posix":
+@@ -235,40 +235,7 @@ elif os.name == "posix":
      else:
  
          def _findSoname_ldconfig(name):
@@ -22,11 +32,20 @@ index b2c514d..a6eca81 100644
 -
 -            # XXX assuming GLIBC's ldconfig (with option -p)
 -            expr = r'\s+(lib%s\.[^\s]+)\s+\(%s' % (re.escape(name), abi_type)
--            f = os.popen('LC_ALL=C LANG=C /sbin/ldconfig -p 2>/dev/null')
+-
+-            env = dict(os.environ)
+-            env['LC_ALL'] = 'C'
+-            env['LANG'] = 'C'
+-            null = open(os.devnull, 'wb')
 -            try:
--                data = f.read()
--            finally:
--                f.close()
+-                with null:
+-                    p = subprocess.Popen(['/sbin/ldconfig', '-p'],
+-                                          stderr=null,
+-                                          stdout=subprocess.PIPE,
+-                                          env=env)
+-            except OSError:  # E.g. command not found
+-                return None
+-            [data, _] = p.communicate()
 -            res = re.search(expr, data)
 -            if not res:
 -                return None
@@ -36,16 +55,12 @@ index b2c514d..a6eca81 100644
          def find_library(name):
              return _findSoname_ldconfig(name) or _get_soname(_findLib_gcc(name))
 diff --git a/Lib/uuid.py b/Lib/uuid.py
-index 7432032..9829d18 100644
+index 7432032..05eeee5 100644
 --- a/Lib/uuid.py
 +++ b/Lib/uuid.py
-@@ -437,57 +437,7 @@ def _netbios_getnode():
-         return ((bytes[0]<<40L) + (bytes[1]<<32L) + (bytes[2]<<24L) +
-                 (bytes[3]<<16L) + (bytes[4]<<8L) + bytes[5])
+@@ -441,53 +441,6 @@ def _netbios_getnode():
  
--# Thanks to Thomas Heller for ctypes and for his help with its use here.
--
--# If ctypes is available, use it to find system routines for UUID generation.
+ # If ctypes is available, use it to find system routines for UUID generation.
  _uuid_generate_time = _UuidCreate = None
 -try:
 -    import ctypes, ctypes.util
@@ -97,3 +112,6 @@ index 7432032..9829d18 100644
  
  def _unixdll_getnode():
      """Get the hardware address on Unix using ctypes."""
+-- 
+2.11.0
+
diff --git a/pkgs/development/interpreters/python/cpython/3.6/default.nix b/pkgs/development/interpreters/python/cpython/3.6/default.nix
index 4654a6e1cb61..8892b0f5c711 100644
--- a/pkgs/development/interpreters/python/cpython/3.6/default.nix
+++ b/pkgs/development/interpreters/python/cpython/3.6/default.nix
@@ -25,7 +25,7 @@ with stdenv.lib;
 let
   majorVersion = "3.6";
   minorVersion = "0";
-  minorVersionSuffix = "rc1";
+  minorVersionSuffix = "";
   pythonVersion = majorVersion;
   version = "${majorVersion}.${minorVersion}${minorVersionSuffix}";
   libPrefix = "python${majorVersion}";
@@ -45,7 +45,7 @@ in stdenv.mkDerivation {
 
   src = fetchurl {
     url = "https://www.python.org/ftp/python/${majorVersion}.${minorVersion}/Python-${version}.tar.xz";
-    sha256 = "01sqzz5iq7law93zgdxkb8sv98a493a2wzslynz64cl3hhdqr1pw";
+    sha256 = "08inlbb2vb8lahw6wfq654lqk6l1x7ncpggp6a92vqw5yq2gkidh";
   };
 
   NIX_LDFLAGS = optionalString stdenv.isLinux "-lgcc_s";
diff --git a/pkgs/development/interpreters/ruby/default.nix b/pkgs/development/interpreters/ruby/default.nix
index 9486d030a8b4..d5f3a6d39902 100644
--- a/pkgs/development/interpreters/ruby/default.nix
+++ b/pkgs/development/interpreters/ruby/default.nix
@@ -113,6 +113,7 @@ let
 
         configureFlags = ["--enable-shared" "--enable-pthread"]
           ++ op useRailsExpress "--with-baseruby=${baseruby}/bin/ruby"
+          ++ op (!docSupport) "--disable-install-doc"
           ++ ops stdenv.isDarwin [
             # on darwin, we have /usr/include/tk.h -- so the configure script detects
             # that tk is installed
@@ -154,7 +155,7 @@ let
           license = stdenv.lib.licenses.ruby;
           homepage = http://www.ruby-lang.org/en/;
           description = "The Ruby language";
-          maintainers = [ stdenv.lib.maintainers.vrthra ];
+          maintainers = with stdenv.lib.maintainers; [ vrthra manveru ];
           platforms = stdenv.lib.platforms.all;
         };
 
@@ -218,4 +219,12 @@ in {
       git = "0cwjf0nrzaa5g81bw0qp65byyadhxvbnvprkshv3ckjl7yi46zf6";
     };
   };
+
+  ruby_2_4_0 = generic {
+    version = rubyVersion "2" "4" "0" "";
+    sha256 = {
+      src = "0gcyn9328w2vma882l71c9v9ygmmsj2z8j1l44c4l2x92nyx0bqm";
+      git = "1w9zyx8xmka8jdiha57snnbfls2r6dc9g03d8cjx0nxkmwf3r2l3";
+    };
+  };
 }
diff --git a/pkgs/development/interpreters/ruby/patchsets.nix b/pkgs/development/interpreters/ruby/patchsets.nix
index d21e7d669dcc..a3aeaf6a8ba0 100644
--- a/pkgs/development/interpreters/ruby/patchsets.nix
+++ b/pkgs/development/interpreters/ruby/patchsets.nix
@@ -65,4 +65,9 @@ rec {
     "${patchSet}/patches/ruby/2.3/head/railsexpress/02-improve-gc-stats.patch"
     "${patchSet}/patches/ruby/2.3/head/railsexpress/03-display-more-detailed-stack-trace.patch"
   ];
+  "2.4.0" = ops useRailsExpress [
+    "${patchSet}/patches/ruby/2.4.0/railsexpress/01-skip-broken-tests.patch"
+    "${patchSet}/patches/ruby/2.4.0/railsexpress/02-improve-gc-stats.patch"
+    "${patchSet}/patches/ruby/2.4.0/railsexpress/03-display-more-detailed-stack-trace.patch"
+  ];
 }
diff --git a/pkgs/development/interpreters/ruby/rvm-patchsets.nix b/pkgs/development/interpreters/ruby/rvm-patchsets.nix
index bbe1038bab2f..51db26b78236 100644
--- a/pkgs/development/interpreters/ruby/rvm-patchsets.nix
+++ b/pkgs/development/interpreters/ruby/rvm-patchsets.nix
@@ -1,8 +1,8 @@
 { fetchFromGitHub }:
 
 fetchFromGitHub {
-  owner  = "skaes";
+  owner  = "manveru";
   repo   = "rvm-patchsets";
-  rev    = "951e47ca1022cd1e41de9177fa87438cfb72d127";
-  sha256 = "18n2frwmn6lcnjywysyjam1zfzfad0r50141xs2h9kifsyak5xcf";
+  rev    = "46e04f230ce91a786f5e583389443efec0ecd594";
+  sha256 = "0ayh8zj8knyz3344an942qdf33pi42jmksqk34frb346zi1ag693";
 }
diff --git a/pkgs/development/libraries/SDL2/default.nix b/pkgs/development/libraries/SDL2/default.nix
index 16aa4f6c2f76..f94d7051d0d9 100644
--- a/pkgs/development/libraries/SDL2/default.nix
+++ b/pkgs/development/libraries/SDL2/default.nix
@@ -31,6 +31,8 @@ stdenv.mkDerivation rec {
     sha256 = "0jqp46mxxbh9lhpx1ih6sp93k752j2smhpc0ad0q4cb3px0famfs";
   };
 
+  outputs = [ "out" "dev" ];
+
   patches = [ ./find-headers.patch ];
 
   nativeBuildInputs = [ pkgconfig ];
@@ -61,6 +63,7 @@ stdenv.mkDerivation rec {
 
   postInstall = ''
     rm $out/lib/*.a
+    moveToOutput bin/sdl2-config "$dev"
   '';
 
   setupHook = ./setup-hook.sh;
diff --git a/pkgs/development/libraries/cairo/default.nix b/pkgs/development/libraries/cairo/default.nix
index 71aa1874951f..5d201c52312f 100644
--- a/pkgs/development/libraries/cairo/default.nix
+++ b/pkgs/development/libraries/cairo/default.nix
@@ -12,11 +12,11 @@ assert glSupport -> mesa_noglu != null;
 with { inherit (stdenv.lib) optional optionals; };
 
 stdenv.mkDerivation rec {
-  name = "cairo-1.14.6";
+  name = "cairo-1.14.8";
 
   src = fetchurl {
     url = "http://cairographics.org/releases/${name}.tar.xz";
-    sha256 = "0lmjlzmghmr27y615px9hkm552x7ap6pmq9mfbzr6smp8y2b6g31";
+    sha1 = "c6f7b99986f93c9df78653c3e6a3b5043f65145e";
   };
 
   infinality = fetchFromGitHub {
diff --git a/pkgs/development/libraries/cyrus-sasl/default.nix b/pkgs/development/libraries/cyrus-sasl/default.nix
index 5bbfd6e375ef..05eb575547d2 100644
--- a/pkgs/development/libraries/cyrus-sasl/default.nix
+++ b/pkgs/development/libraries/cyrus-sasl/default.nix
@@ -2,7 +2,8 @@
 
 with stdenv.lib;
 stdenv.mkDerivation rec {
-  name = "cyrus-sasl-2.1.26${optionalString (kerberos == null) "-without-kerberos"}";
+  name = "cyrus-sasl-${version}${optionalString (kerberos == null) "-without-kerberos"}";
+  version = "2.5.10";
 
   src = fetchurl {
     url = "ftp://ftp.cyrusimap.org/cyrus-sasl/${name}.tar.gz";
diff --git a/pkgs/development/libraries/glib/default.nix b/pkgs/development/libraries/glib/default.nix
index 87c511f00ddf..c7c704c641f8 100644
--- a/pkgs/development/libraries/glib/default.nix
+++ b/pkgs/development/libraries/glib/default.nix
@@ -99,7 +99,12 @@ stdenv.mkDerivation rec {
     moveToOutput "share/glib-2.0" "$dev"
     substituteInPlace "$dev/bin/gdbus-codegen" --replace "$out" "$dev"
     sed -i "$dev/bin/glib-gettextize" -e "s|^gettext_dir=.*|gettext_dir=$dev/share/glib-2.0/gettext|"
-  '';
+  ''
+    # This file is *included* in gtk3 and would introduce runtime reference via __FILE__.
+    + ''
+      sed '1i#line 1 "${name}/include/glib-2.0/gobject/gobjectnotifyqueue.c"' \
+        -i "$dev"/include/glib-2.0/gobject/gobjectnotifyqueue.c
+    '';
 
   inherit doCheck;
   preCheck = optionalString doCheck
diff --git a/pkgs/development/libraries/gtk+/3.x.nix b/pkgs/development/libraries/gtk+/3.x.nix
index b50264f3a02a..1b938215d176 100644
--- a/pkgs/development/libraries/gtk+/3.x.nix
+++ b/pkgs/development/libraries/gtk+/3.x.nix
@@ -13,7 +13,7 @@ with stdenv.lib;
 
 let
   ver_maj = "3.22";
-  ver_min = "4";
+  ver_min = "5";
   version = "${ver_maj}.${ver_min}";
 in
 stdenv.mkDerivation rec {
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   src = fetchurl {
     url = "mirror://gnome/sources/gtk+/${ver_maj}/gtk+-${version}.tar.xz";
-    sha256 = "0zrq3wq4x0vcrzapps0608d5ywcrwk9xb2rmg32h2g8kzvyad53h";
+    sha256 = "693fa0ac643c59ccd51db99cabe476b4e0a41fd4f0c3c8b3e3ef38f94b2e7334";
   };
 
   outputs = [ "out" "dev" ];
diff --git a/pkgs/development/libraries/json-glib/default.nix b/pkgs/development/libraries/json-glib/default.nix
index 9505192ef8ab..9d434c088bad 100644
--- a/pkgs/development/libraries/json-glib/default.nix
+++ b/pkgs/development/libraries/json-glib/default.nix
@@ -17,6 +17,8 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS = stdenv.lib.optionalString stdenv.isDarwin "-lintl";
 
+  outputs = [ "out" "dev" ];
+
   meta = with stdenv.lib; {
     homepage = http://live.gnome.org/JsonGlib;
     description = "A library providing (de)serialization support for the JavaScript Object Notation (JSON) format";
diff --git a/pkgs/development/libraries/kerberos/krb5.nix b/pkgs/development/libraries/kerberos/krb5.nix
index 8fda2b7e5843..1b8c274c4574 100644
--- a/pkgs/development/libraries/kerberos/krb5.nix
+++ b/pkgs/development/libraries/kerberos/krb5.nix
@@ -11,11 +11,12 @@ in
 with stdenv.lib;
 stdenv.mkDerivation rec {
   name = "${type}krb5-${version}";
-  version = "1.14.3";
+  majorVersion = "1.15";
+  version = "${majorVersion}";
 
   src = fetchurl {
-    url = "${meta.homepage}dist/krb5/1.14/krb5-${version}.tar.gz";
-    sha256 = "1jgjiyh1sp72lkxvk437lz5hzcibvw99jc4ihzfz03fg43aj0ind";
+    url = "${meta.homepage}dist/krb5/${majorVersion}/krb5-${version}.tar.gz";
+    sha256 = "0z0jxm6ppbxi9anv2h12nrb5lpwl95f96kw6dx7sn268fhkpad7x";
   };
 
   configureFlags = optional stdenv.isFreeBSD ''WARN_CFLAGS=""'';
@@ -26,8 +27,6 @@ stdenv.mkDerivation rec {
   buildInputs = [ openssl ]
     ++ optionals (!libOnly) [ openldap libedit ];
 
-  patches = [ ./path_char_fix.patch ];
-
   preConfigure = "cd ./src";
 
   buildPhase = optionalString libOnly ''
diff --git a/pkgs/development/libraries/kerberos/path_char_fix.patch b/pkgs/development/libraries/kerberos/path_char_fix.patch
deleted file mode 100644
index 2a6dc4c11c37..000000000000
--- a/pkgs/development/libraries/kerberos/path_char_fix.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-See https://github.com/krb5/krb5/pull/467
-diff --git a/src/include/Makefile.in b/src/include/Makefile.in
-index 4bb11e4..cb4b44b 100644
---- a/src/include/Makefile.in
-+++ b/src/include/Makefile.in
-@@ -57,19 +57,19 @@ SBINDIR = @sbindir@
- LIBDIR  = @libdir@
- SYSCONFCONF = @SYSCONFCONF@
- 
--PROCESS_REPLACE = -e "s+@KRB5RCTMPDIR+$(KRB5RCTMPDIR)+" \
--		  -e "s+@PREFIX+$(INSTALL_PREFIX)+" \
--		  -e "s+@EXEC_PREFIX+$(INSTALL_EXEC_PREFIX)+" \
--		  -e "s+@BINDIR+$(BINDIR)+" \
--		  -e "s+@LIBDIR+$(LIBDIR)+" \
--		  -e "s+@SBINDIR+$(SBINDIR)+" \
--		  -e "s+@MODULEDIR+$(MODULE_DIR)+" \
--		  -e "s+@GSSMODULEDIR+$(GSS_MODULE_DIR)+" \
--		  -e 's+@LOCALSTATEDIR+$(LOCALSTATEDIR)+' \
--		  -e 's+@RUNSTATEDIR+$(RUNSTATEDIR)+' \
--		  -e 's+@SYSCONFDIR+$(SYSCONFDIR)+' \
--		  -e 's+@DYNOBJEXT+$(DYNOBJEXT)+' \
--		  -e 's+@SYSCONFCONF+$(SYSCONFCONF)+'
-+PROCESS_REPLACE = -e "s\"@KRB5RCTMPDIR\"$(KRB5RCTMPDIR)\"" \
-+		  -e "s\"@PREFIX\"$(INSTALL_PREFIX)\"" \
-+		  -e "s\"@EXEC_PREFIX\"$(INSTALL_EXEC_PREFIX)\"" \
-+		  -e "s\"@BINDIR\"$(BINDIR)\"" \
-+		  -e "s\"@LIBDIR\"$(LIBDIR)\"" \
-+		  -e "s\"@SBINDIR\"$(SBINDIR)\"" \
-+		  -e "s\"@MODULEDIR\"$(MODULE_DIR)\"" \
-+		  -e "s\"@GSSMODULEDIR\"$(GSS_MODULE_DIR)\"" \
-+		  -e "s\"@LOCALSTATEDIR\"$(LOCALSTATEDIR)\"" \
-+		  -e "s\"@RUNSTATEDIR\"$(RUNSTATEDIR)\"" \
-+		  -e "s\"@SYSCONFDIR\"$(SYSCONFDIR)\"" \
-+		  -e "s\"@DYNOBJEXT\"$(DYNOBJEXT)\"" \
-+		  -e "s\"@SYSCONFCONF\"$(SYSCONFCONF)\""
- 
- OSCONFSRC = $(srcdir)/osconf.hin
- 
diff --git a/pkgs/development/libraries/libuv/default.nix b/pkgs/development/libraries/libuv/default.nix
index db77a6fefc3a..f9e7cf389bbb 100644
--- a/pkgs/development/libraries/libuv/default.nix
+++ b/pkgs/development/libraries/libuv/default.nix
@@ -1,5 +1,4 @@
 { stdenv, lib, fetchFromGitHub, autoconf, automake, libtool, pkgconfig
-
 , ApplicationServices, CoreServices }:
 
 stdenv.mkDerivation rec {
@@ -13,10 +12,15 @@ stdenv.mkDerivation rec {
     sha256 = "0gna53fgsjjs38kv1g20xfaalv0fk3xncb6abga3saswrv283hx0";
   };
 
-  # these checks are probably network-dependent
-  postPatch = lib.optionalString doCheck ''
-    sed '/getnameinfo_basic/d' -i test/test-list.h
-  '';
+  postPatch = let
+    toDisable = [
+      "getnameinfo_basic" # probably network-dependent
+      "spawn_setuid_fails" "spawn_setgid_fails" "fs_chown" # user namespaces
+    ];
+    tdRegexp = lib.concatStringsSep "\\|" toDisable;
+    in lib.optionalString doCheck ''
+      sed '/${tdRegexp}/d' -i test/test-list.h
+    '';
 
   buildInputs = [ automake autoconf libtool pkgconfig ]
     ++ stdenv.lib.optionals stdenv.isDarwin [ ApplicationServices CoreServices ];
diff --git a/pkgs/development/libraries/libwacom/default.nix b/pkgs/development/libraries/libwacom/default.nix
index 0d757d33cf95..ad3cbe119c55 100644
--- a/pkgs/development/libraries/libwacom/default.nix
+++ b/pkgs/development/libraries/libwacom/default.nix
@@ -2,11 +2,11 @@
 
 stdenv.mkDerivation rec {
   name = "libwacom-${version}";
-  version = "0.19";
+  version = "0.22";
 
   src = fetchurl {
     url = "mirror://sourceforge/linuxwacom/libwacom/${name}.tar.bz2";
-    sha256 = "1zsmp2l53fbfy6jykh4c0i127baf503lq2fvd5y1066ihp6qh3b2";
+    sha256 = "1h10awwapj5v8nik220ga0raggv3lgaq0kzwlma2qjmzdhhrrhcp";
   };
 
   nativeBuildInputs = [ pkgconfig ];
diff --git a/pkgs/development/libraries/ncurses/default.nix b/pkgs/development/libraries/ncurses/default.nix
index 3eff1f3d5bbd..bbf7d7108dd0 100644
--- a/pkgs/development/libraries/ncurses/default.nix
+++ b/pkgs/development/libraries/ncurses/default.nix
@@ -102,6 +102,9 @@ stdenv.mkDerivation rec {
       done
     done
 
+    # create libtinfo symlink
+    ln -svf $out/lib/libncurses.$dylibtype $out/libtinfo.$dylibtype
+        
     # move some utilities to $bin
     # these programs are used at runtime and don't really belong in $dev
     moveToOutput "bin/clear" "$out"
diff --git a/pkgs/development/libraries/nghttp2/default.nix b/pkgs/development/libraries/nghttp2/default.nix
index 080a3e35138e..f7a026c52d46 100644
--- a/pkgs/development/libraries/nghttp2/default.nix
+++ b/pkgs/development/libraries/nghttp2/default.nix
@@ -1,26 +1,20 @@
 { stdenv, fetchurl, pkgconfig
 
 # Optional Dependencies
-, openssl ? null, libev ? null, zlib ? null, jansson ? null, boost ? null
-, libxml2 ? null, jemalloc ? null
+, openssl ? null, libev ? null, zlib ? null
+#, jansson ? null, boost ? null, libxml2 ? null, jemalloc ? null
 }:
 
 stdenv.mkDerivation rec {
   name = "nghttp2-${version}";
-  version = "1.16.1";
+  version = "1.17.0";
 
   # Don't use fetchFromGitHub since this needs a bootstrap curl
   src = fetchurl {
     url = "https://github.com/nghttp2/nghttp2/releases/download/v${version}/nghttp2-${version}.tar.bz2";
-    sha256 = "069pw84f8gg21npapn7y1sizwn6w35692zaq5g45gy8hdbmcl8yc";
+    sha256 = "7685b6717d205d3a251b7dd5e73a7ca5e643bc5c01f928b82bfeed30c243f28a";
   };
 
-  # Configure script searches for a symbol which does not exist in jemalloc on Darwin
-  # Reported upstream in https://github.com/tatsuhiro-t/nghttp2/issues/233
-  postPatch = if stdenv.isDarwin && jemalloc != null then ''
-    substituteInPlace configure --replace "malloc_stats_print" "je_malloc_stats_print"
-  '' else null;
-
   outputs = [ "out" "dev" "lib" ];
 
   nativeBuildInputs = [ pkgconfig ];
diff --git a/pkgs/development/libraries/science/biology/htslib/default.nix b/pkgs/development/libraries/science/biology/htslib/default.nix
index 2609861e319e..29fb338c8389 100644
--- a/pkgs/development/libraries/science/biology/htslib/default.nix
+++ b/pkgs/development/libraries/science/biology/htslib/default.nix
@@ -3,11 +3,11 @@
 stdenv.mkDerivation rec {
   name = "${pname}-${version}";
   pname = "htslib";
-  version = "1.3.1";
+  version = "1.3.2";
 
   src = fetchurl {
     url = "https://github.com/samtools/${pname}/releases/download/${version}/${name}.tar.bz2";
-    sha256 = "49d53a2395b8cef7d1d11270a09de888df8ba06f70fe68282e8235ee04124ae6";
+    sha256 = "0iq3blw23s55vkr1z88p9y2dqrb2dybzhl6hz2nlk53ncihrxcdr";
   };
 
   buildInputs = [ zlib ];
diff --git a/pkgs/development/libraries/simgear/default.nix b/pkgs/development/libraries/simgear/default.nix
index df732c40f57e..aef1a1dc8222 100644
--- a/pkgs/development/libraries/simgear/default.nix
+++ b/pkgs/development/libraries/simgear/default.nix
@@ -1,20 +1,22 @@
 { stdenv, fetchurl, plib, freeglut, xproto, libX11, libXext, xextproto, libXi
 , inputproto, libICE, libSM, libXt, libXmu, mesa, boost, zlib, libjpeg, freealut
 , openscenegraph, openal, expat, cmake, apr
+, curl
 }:
 
 stdenv.mkDerivation rec {
   name = "simgear-${version}";
-  version = "3.4.0";
+  version = "2016.4.3";
+  shortVersion = "2016.4";
 
   src = fetchurl {
-    url = "http://mirrors.ibiblio.org/pub/mirrors/simgear/ftp/Source/${name}.tar.bz2";
-    sha256 = "152q3aqlrg3631ppvl6kr1mp5iszplq68l6lrsn9vjxafbz6czcj";
+    url = "mirror://sourceforge/flightgear/release-${shortVersion}/${name}.tar.bz2";
+    sha256 = "1gfj0d03jbi0p08baj46ihhyzbgpymmipw2dp11j13412l15acv9";
   };
 
   buildInputs = [ plib freeglut xproto libX11 libXext xextproto libXi inputproto
                   libICE libSM libXt libXmu mesa boost zlib libjpeg freealut
-                  openscenegraph openal expat cmake apr ];
+                  openscenegraph openal expat cmake apr curl ];
 
   meta = with stdenv.lib; {
     description = "Simulation construction toolkit";
diff --git a/pkgs/development/libraries/wxmac/default.nix b/pkgs/development/libraries/wxmac/default.nix
index e5d680501f00..f4e714248338 100644
--- a/pkgs/development/libraries/wxmac/default.nix
+++ b/pkgs/development/libraries/wxmac/default.nix
@@ -1,7 +1,7 @@
-{ stdenv, fetchurl
-, expat, libiconv, libjpeg, libpng, libtiff, zlib
-, setfile, rez, derez
-, AGL, Cocoa, Kernel, QuickTime
+{ stdenv, fetchurl, fetchpatch, expat, libiconv, libjpeg, libpng, libtiff, zlib
+# darwin only attributes
+, derez, rez, setfile
+, AGL, Cocoa, Kernel
 }:
 
 with stdenv.lib;
@@ -15,11 +15,46 @@ stdenv.mkDerivation rec {
     sha256 = "346879dc554f3ab8d6da2704f651ecb504a22e9d31c17ef5449b129ed711585d";
   };
 
-  patches = [ ./wx.patch ];
+  patches =
+    [ # Use std::abs() from <cmath> instead of abs() from <math.h> to avoid problems
+      # with abiguous overloads for clang-3.8 and gcc6.
+      (fetchpatch {
+        name = "patch-stc-abs.diff";
+        url = https://github.com/wxWidgets/wxWidgets/commit/73e9e18ea09ffffcaac50237def0d9728a213c02.patch;
+        sha256 = "0w5whmfzm8waw62jmippming0zffa9064m5b3aw5nixph21rlcvq";
+      })
+
+      # Various fixes related to Yosemite. Revisit in next stable release.
+      # Please keep an eye on http://trac.wxwidgets.org/ticket/16329 as well
+      # Theoretically the above linked patch should still be needed, but it isn't.
+      # Try to find out why.
+      (fetchpatch {
+        name = "patch-yosemite.diff";
+        url = https://raw.githubusercontent.com/Homebrew/formula-patches/bbf4995/wxmac/patch-yosemite.diff;
+        sha256 = "0ss66z2a79v976mvlrskyj1zmkyaz8hbwm98p29bscfvcx5845jb";
+      })
+
+      # Remove uncenessary <QuickTime/QuickTime.h> includes
+      # http://trac.wxwidgets.org/changeset/f6a2d1caef5c6d412c84aa900cb0d3990b350938/git-wxWidgets
+      (fetchpatch {
+        name = "patch-quicktime-removal.diff";
+        url = https://raw.githubusercontent.com/Homebrew/formula-patches/bbf4995/wxmac/patch-quicktime-removal.diff;
+        sha256 = "0mzvdk8r70p9s1wj7qzdsqmdrlxlf2dalh9gqs8xjkqq2666yp0y";
+      })
+
+      # Patch for wxOSXPrintData, custom paper not applied
+      # http://trac.wxwidgets.org/ticket/16959
+      (fetchpatch {
+        name = "wxPaperCustomPatch.patch";
+        url = http://trac.wxwidgets.org/raw-attachment/ticket/16959/wxPaperCustomPatch.patch;
+        sha256 = "0xgscv86f8dhggn9n8bhlq9wlj3ydsicgy9v35sraxyma18cbjvl";
+      })
+    ];
 
   buildInputs = [
     expat libiconv libjpeg libpng libtiff zlib
-    Cocoa Kernel QuickTime setfile rez derez
+    derez rez setfile
+    Cocoa Kernel
   ];
 
   propagatedBuildInputs = [ AGL ];
diff --git a/pkgs/development/libraries/wxmac/wx.patch b/pkgs/development/libraries/wxmac/wx.patch
deleted file mode 100644
index 622e22d1fdb4..000000000000
--- a/pkgs/development/libraries/wxmac/wx.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-diff --git a/include/wx/defs.h b/include/wx/defs.h
-index 397ddd7..d128083 100644
---- a/include/wx/defs.h
-+++ b/include/wx/defs.h
-@@ -3169,12 +3169,20 @@ DECLARE_WXCOCOA_OBJC_CLASS(UIImage);
- DECLARE_WXCOCOA_OBJC_CLASS(UIEvent);
- DECLARE_WXCOCOA_OBJC_CLASS(NSSet);
- DECLARE_WXCOCOA_OBJC_CLASS(EAGLContext);
-+DECLARE_WXCOCOA_OBJC_CLASS(UIWebView);
- 
- typedef WX_UIWindow WXWindow;
- typedef WX_UIView WXWidget;
- typedef WX_EAGLContext WXGLContext;
- typedef WX_NSString* WXGLPixelFormat;
- 
-+typedef WX_UIWebView OSXWebViewPtr;
-+
-+#endif
-+
-+#if wxOSX_USE_COCOA_OR_CARBON
-+DECLARE_WXCOCOA_OBJC_CLASS(WebView);
-+typedef WX_WebView OSXWebViewPtr;
- #endif
- 
- #endif /* __WXMAC__ */
-diff --git a/include/wx/html/webkit.h b/include/wx/html/webkit.h
-index 8700367..f805099 100644
---- a/include/wx/html/webkit.h
-+++ b/include/wx/html/webkit.h
-@@ -18,7 +18,6 @@
- #endif
- 
- #include "wx/control.h"
--DECLARE_WXCOCOA_OBJC_CLASS(WebView); 
- 
- // ----------------------------------------------------------------------------
- // Web Kit Control
-@@ -107,7 +106,7 @@ private:
-     wxString m_currentURL;
-     wxString m_pageTitle;
- 
--    WX_WebView m_webView;
-+    OSXWebViewPtr m_webView;
- 
-     // we may use this later to setup our own mouse events,
-     // so leave it in for now.
-diff --git a/include/wx/osx/webview_webkit.h b/include/wx/osx/webview_webkit.h
-index 803f8b0..438e532 100644
---- a/include/wx/osx/webview_webkit.h
-+++ b/include/wx/osx/webview_webkit.h
-@@ -158,7 +158,7 @@ private:
-     wxWindowID m_windowID;
-     wxString m_pageTitle;
- 
--    wxObjCID m_webView;
-+    OSXWebViewPtr m_webView;
- 
-     // we may use this later to setup our own mouse events,
-     // so leave it in for now.
diff --git a/pkgs/development/libraries/zlib/CVE-2016-9840.patch b/pkgs/development/libraries/zlib/CVE-2016-9840.patch
new file mode 100644
index 000000000000..a8b84ff84132
--- /dev/null
+++ b/pkgs/development/libraries/zlib/CVE-2016-9840.patch
@@ -0,0 +1,71 @@
+From 6a043145ca6e9c55184013841a67b2fef87e44c0 Mon Sep 17 00:00:00 2001
+From: Mark Adler <madler@alumni.caltech.edu>
+Date: Wed, 21 Sep 2016 23:35:50 -0700
+Subject: [PATCH] Remove offset pointer optimization in inftrees.c.
+
+inftrees.c was subtracting an offset from a pointer to an array,
+in order to provide a pointer that allowed indexing starting at
+the offset. This is not compliant with the C standard, for which
+the behavior of a pointer decremented before its allocated memory
+is undefined. Per the recommendation of a security audit of the
+zlib code by Trail of Bits and TrustInSoft, in support of the
+Mozilla Foundation, this tiny optimization was removed, in order
+to avoid the possibility of undefined behavior.
+---
+ inftrees.c | 18 ++++++++----------
+ 1 file changed, 8 insertions(+), 10 deletions(-)
+
+diff --git a/inftrees.c b/inftrees.c
+index 22fcd66..0d2670d 100644
+--- a/inftrees.c
++++ b/inftrees.c
+@@ -54,7 +54,7 @@ unsigned short FAR *work;
+     code FAR *next;             /* next available space in table */
+     const unsigned short FAR *base;     /* base value table to use */
+     const unsigned short FAR *extra;    /* extra bits table to use */
+-    int end;                    /* use base and extra for symbol > end */
++    unsigned match;             /* use base and extra for symbol >= match */
+     unsigned short count[MAXBITS+1];    /* number of codes of each length */
+     unsigned short offs[MAXBITS+1];     /* offsets in table for each length */
+     static const unsigned short lbase[31] = { /* Length codes 257..285 base */
+@@ -181,19 +181,17 @@ unsigned short FAR *work;
+     switch (type) {
+     case CODES:
+         base = extra = work;    /* dummy value--not used */
+-        end = 19;
++        match = 20;
+         break;
+     case LENS:
+         base = lbase;
+-        base -= 257;
+         extra = lext;
+-        extra -= 257;
+-        end = 256;
++        match = 257;
+         break;
+     default:            /* DISTS */
+         base = dbase;
+         extra = dext;
+-        end = -1;
++        match = 0;
+     }
+ 
+     /* initialize state for loop */
+@@ -216,13 +214,13 @@ unsigned short FAR *work;
+     for (;;) {
+         /* create table entry */
+         here.bits = (unsigned char)(len - drop);
+-        if ((int)(work[sym]) < end) {
++        if (work[sym] + 1 < match) {
+             here.op = (unsigned char)0;
+             here.val = work[sym];
+         }
+-        else if ((int)(work[sym]) > end) {
+-            here.op = (unsigned char)(extra[work[sym]]);
+-            here.val = base[work[sym]];
++        else if (work[sym] >= match) {
++            here.op = (unsigned char)(extra[work[sym] - match]);
++            here.val = base[work[sym] - match];
+         }
+         else {
+             here.op = (unsigned char)(32 + 64);         /* end of block */
diff --git a/pkgs/development/libraries/zlib/CVE-2016-9841.patch b/pkgs/development/libraries/zlib/CVE-2016-9841.patch
new file mode 100644
index 000000000000..e350b3d96423
--- /dev/null
+++ b/pkgs/development/libraries/zlib/CVE-2016-9841.patch
@@ -0,0 +1,224 @@
+From 9aaec95e82117c1cb0f9624264c3618fc380cecb Mon Sep 17 00:00:00 2001
+From: Mark Adler <madler@alumni.caltech.edu>
+Date: Wed, 21 Sep 2016 22:25:21 -0700
+Subject: [PATCH] Use post-increment only in inffast.c.
+
+An old inffast.c optimization turns out to not be optimal anymore
+with modern compilers, and furthermore was not compliant with the
+C standard, for which decrementing a pointer before its allocated
+memory is undefined. Per the recommendation of a security audit of
+the zlib code by Trail of Bits and TrustInSoft, in support of the
+Mozilla Foundation, this "optimization" was removed, in order to
+avoid the possibility of undefined behavior.
+---
+ inffast.c | 81 ++++++++++++++++++++++++---------------------------------------
+ 1 file changed, 31 insertions(+), 50 deletions(-)
+
+diff --git a/inffast.c b/inffast.c
+index bda59ce..f0d163d 100644
+--- a/inffast.c
++++ b/inffast.c
+@@ -10,25 +10,6 @@
+ 
+ #ifndef ASMINF
+ 
+-/* Allow machine dependent optimization for post-increment or pre-increment.
+-   Based on testing to date,
+-   Pre-increment preferred for:
+-   - PowerPC G3 (Adler)
+-   - MIPS R5000 (Randers-Pehrson)
+-   Post-increment preferred for:
+-   - none
+-   No measurable difference:
+-   - Pentium III (Anderson)
+-   - M68060 (Nikl)
+- */
+-#ifdef POSTINC
+-#  define OFF 0
+-#  define PUP(a) *(a)++
+-#else
+-#  define OFF 1
+-#  define PUP(a) *++(a)
+-#endif
+-
+ /*
+    Decode literal, length, and distance codes and write out the resulting
+    literal and match bytes until either not enough input or output is
+@@ -96,9 +77,9 @@ unsigned start;         /* inflate()'s starting value for strm->avail_out */
+ 
+     /* copy state to local variables */
+     state = (struct inflate_state FAR *)strm->state;
+-    in = strm->next_in - OFF;
++    in = strm->next_in;
+     last = in + (strm->avail_in - 5);
+-    out = strm->next_out - OFF;
++    out = strm->next_out;
+     beg = out - (start - strm->avail_out);
+     end = out + (strm->avail_out - 257);
+ #ifdef INFLATE_STRICT
+@@ -119,9 +100,9 @@ unsigned start;         /* inflate()'s starting value for strm->avail_out */
+        input data or output space */
+     do {
+         if (bits < 15) {
+-            hold += (unsigned long)(PUP(in)) << bits;
++            hold += (unsigned long)(*in++) << bits;
+             bits += 8;
+-            hold += (unsigned long)(PUP(in)) << bits;
++            hold += (unsigned long)(*in++) << bits;
+             bits += 8;
+         }
+         here = lcode[hold & lmask];
+@@ -134,14 +115,14 @@ unsigned start;         /* inflate()'s starting value for strm->avail_out */
+             Tracevv((stderr, here.val >= 0x20 && here.val < 0x7f ?
+                     "inflate:         literal '%c'\n" :
+                     "inflate:         literal 0x%02x\n", here.val));
+-            PUP(out) = (unsigned char)(here.val);
++            *out++ = (unsigned char)(here.val);
+         }
+         else if (op & 16) {                     /* length base */
+             len = (unsigned)(here.val);
+             op &= 15;                           /* number of extra bits */
+             if (op) {
+                 if (bits < op) {
+-                    hold += (unsigned long)(PUP(in)) << bits;
++                    hold += (unsigned long)(*in++) << bits;
+                     bits += 8;
+                 }
+                 len += (unsigned)hold & ((1U << op) - 1);
+@@ -150,9 +131,9 @@ unsigned start;         /* inflate()'s starting value for strm->avail_out */
+             }
+             Tracevv((stderr, "inflate:         length %u\n", len));
+             if (bits < 15) {
+-                hold += (unsigned long)(PUP(in)) << bits;
++                hold += (unsigned long)(*in++) << bits;
+                 bits += 8;
+-                hold += (unsigned long)(PUP(in)) << bits;
++                hold += (unsigned long)(*in++) << bits;
+                 bits += 8;
+             }
+             here = dcode[hold & dmask];
+@@ -165,10 +146,10 @@ unsigned start;         /* inflate()'s starting value for strm->avail_out */
+                 dist = (unsigned)(here.val);
+                 op &= 15;                       /* number of extra bits */
+                 if (bits < op) {
+-                    hold += (unsigned long)(PUP(in)) << bits;
++                    hold += (unsigned long)(*in++) << bits;
+                     bits += 8;
+                     if (bits < op) {
+-                        hold += (unsigned long)(PUP(in)) << bits;
++                        hold += (unsigned long)(*in++) << bits;
+                         bits += 8;
+                     }
+                 }
+@@ -196,30 +177,30 @@ unsigned start;         /* inflate()'s starting value for strm->avail_out */
+ #ifdef INFLATE_ALLOW_INVALID_DISTANCE_TOOFAR_ARRR
+                         if (len <= op - whave) {
+                             do {
+-                                PUP(out) = 0;
++                                *out++ = 0;
+                             } while (--len);
+                             continue;
+                         }
+                         len -= op - whave;
+                         do {
+-                            PUP(out) = 0;
++                            *out++ = 0;
+                         } while (--op > whave);
+                         if (op == 0) {
+                             from = out - dist;
+                             do {
+-                                PUP(out) = PUP(from);
++                                *out++ = *from++;
+                             } while (--len);
+                             continue;
+                         }
+ #endif
+                     }
+-                    from = window - OFF;
++                    from = window;
+                     if (wnext == 0) {           /* very common case */
+                         from += wsize - op;
+                         if (op < len) {         /* some from window */
+                             len -= op;
+                             do {
+-                                PUP(out) = PUP(from);
++                                *out++ = *from++;
+                             } while (--op);
+                             from = out - dist;  /* rest from output */
+                         }
+@@ -230,14 +211,14 @@ unsigned start;         /* inflate()'s starting value for strm->avail_out */
+                         if (op < len) {         /* some from end of window */
+                             len -= op;
+                             do {
+-                                PUP(out) = PUP(from);
++                                *out++ = *from++;
+                             } while (--op);
+-                            from = window - OFF;
++                            from = window;
+                             if (wnext < len) {  /* some from start of window */
+                                 op = wnext;
+                                 len -= op;
+                                 do {
+-                                    PUP(out) = PUP(from);
++                                    *out++ = *from++;
+                                 } while (--op);
+                                 from = out - dist;      /* rest from output */
+                             }
+@@ -248,35 +229,35 @@ unsigned start;         /* inflate()'s starting value for strm->avail_out */
+                         if (op < len) {         /* some from window */
+                             len -= op;
+                             do {
+-                                PUP(out) = PUP(from);
++                                *out++ = *from++;
+                             } while (--op);
+                             from = out - dist;  /* rest from output */
+                         }
+                     }
+                     while (len > 2) {
+-                        PUP(out) = PUP(from);
+-                        PUP(out) = PUP(from);
+-                        PUP(out) = PUP(from);
++                        *out++ = *from++;
++                        *out++ = *from++;
++                        *out++ = *from++;
+                         len -= 3;
+                     }
+                     if (len) {
+-                        PUP(out) = PUP(from);
++                        *out++ = *from++;
+                         if (len > 1)
+-                            PUP(out) = PUP(from);
++                            *out++ = *from++;
+                     }
+                 }
+                 else {
+                     from = out - dist;          /* copy direct from output */
+                     do {                        /* minimum length is three */
+-                        PUP(out) = PUP(from);
+-                        PUP(out) = PUP(from);
+-                        PUP(out) = PUP(from);
++                        *out++ = *from++;
++                        *out++ = *from++;
++                        *out++ = *from++;
+                         len -= 3;
+                     } while (len > 2);
+                     if (len) {
+-                        PUP(out) = PUP(from);
++                        *out++ = *from++;
+                         if (len > 1)
+-                            PUP(out) = PUP(from);
++                            *out++ = *from++;
+                     }
+                 }
+             }
+@@ -313,8 +294,8 @@ unsigned start;         /* inflate()'s starting value for strm->avail_out */
+     hold &= (1U << bits) - 1;
+ 
+     /* update state and return */
+-    strm->next_in = in + OFF;
+-    strm->next_out = out + OFF;
++    strm->next_in = in;
++    strm->next_out = out;
+     strm->avail_in = (unsigned)(in < last ? 5 + (last - in) : 5 - (in - last));
+     strm->avail_out = (unsigned)(out < end ?
+                                  257 + (end - out) : 257 - (out - end));
diff --git a/pkgs/development/libraries/zlib/CVE-2016-9842.patch b/pkgs/development/libraries/zlib/CVE-2016-9842.patch
new file mode 100644
index 000000000000..e729f7e162cb
--- /dev/null
+++ b/pkgs/development/libraries/zlib/CVE-2016-9842.patch
@@ -0,0 +1,29 @@
+From e54e1299404101a5a9d0cf5e45512b543967f958 Mon Sep 17 00:00:00 2001
+From: Mark Adler <madler@alumni.caltech.edu>
+Date: Sat, 5 Sep 2015 17:45:55 -0700
+Subject: [PATCH] Avoid shifts of negative values inflateMark().
+
+The C standard says that bit shifts of negative integers is
+undefined.  This casts to unsigned values to assure a known
+result.
+---
+ inflate.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/inflate.c b/inflate.c
+index 2889e3a..a718416 100644
+--- a/inflate.c
++++ b/inflate.c
+@@ -1506,9 +1506,10 @@ z_streamp strm;
+ {
+     struct inflate_state FAR *state;
+ 
+-    if (strm == Z_NULL || strm->state == Z_NULL) return -1L << 16;
++    if (strm == Z_NULL || strm->state == Z_NULL)
++        return (long)(((unsigned long)0 - 1) << 16);
+     state = (struct inflate_state FAR *)strm->state;
+-    return ((long)(state->back) << 16) +
++    return (long)(((unsigned long)((long)state->back)) << 16) +
+         (state->mode == COPY ? state->length :
+             (state->mode == MATCH ? state->was - state->length : 0));
+ }
diff --git a/pkgs/development/libraries/zlib/CVE-2016-9843.patch b/pkgs/development/libraries/zlib/CVE-2016-9843.patch
new file mode 100644
index 000000000000..1fe4c4daa03c
--- /dev/null
+++ b/pkgs/development/libraries/zlib/CVE-2016-9843.patch
@@ -0,0 +1,49 @@
+From d1d577490c15a0c6862473d7576352a9f18ef811 Mon Sep 17 00:00:00 2001
+From: Mark Adler <madler@alumni.caltech.edu>
+Date: Wed, 28 Sep 2016 20:20:25 -0700
+Subject: [PATCH] Avoid pre-decrement of pointer in big-endian CRC calculation.
+
+There was a small optimization for PowerPCs to pre-increment a
+pointer when accessing a word, instead of post-incrementing. This
+required prefacing the loop with a decrement of the pointer,
+possibly pointing before the object passed. This is not compliant
+with the C standard, for which decrementing a pointer before its
+allocated memory is undefined. When tested on a modern PowerPC
+with a modern compiler, the optimization no longer has any effect.
+Due to all that, and per the recommendation of a security audit of
+the zlib code by Trail of Bits and TrustInSoft, in support of the
+Mozilla Foundation, this "optimization" was removed, in order to
+avoid the possibility of undefined behavior.
+---
+ crc32.c | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+diff --git a/crc32.c b/crc32.c
+index 979a719..05733f4 100644
+--- a/crc32.c
++++ b/crc32.c
+@@ -278,7 +278,7 @@ local unsigned long crc32_little(crc, buf, len)
+ }
+ 
+ /* ========================================================================= */
+-#define DOBIG4 c ^= *++buf4; \
++#define DOBIG4 c ^= *buf4++; \
+         c = crc_table[4][c & 0xff] ^ crc_table[5][(c >> 8) & 0xff] ^ \
+             crc_table[6][(c >> 16) & 0xff] ^ crc_table[7][c >> 24]
+ #define DOBIG32 DOBIG4; DOBIG4; DOBIG4; DOBIG4; DOBIG4; DOBIG4; DOBIG4; DOBIG4
+@@ -300,7 +300,6 @@ local unsigned long crc32_big(crc, buf, len)
+     }
+ 
+     buf4 = (const z_crc_t FAR *)(const void FAR *)buf;
+-    buf4--;
+     while (len >= 32) {
+         DOBIG32;
+         len -= 32;
+@@ -309,7 +308,6 @@ local unsigned long crc32_big(crc, buf, len)
+         DOBIG4;
+         len -= 4;
+     }
+-    buf4++;
+     buf = (const unsigned char FAR *)buf4;
+ 
+     if (len) do {
diff --git a/pkgs/development/libraries/zlib/default.nix b/pkgs/development/libraries/zlib/default.nix
index e61001e7d6db..21a7e81ce3ed 100644
--- a/pkgs/development/libraries/zlib/default.nix
+++ b/pkgs/development/libraries/zlib/default.nix
@@ -13,6 +13,13 @@ stdenv.mkDerivation rec {
     sha256 = "039agw5rqvqny92cpkrfn243x2gd4xn13hs3xi6isk55d2vqqr9n";
   };
 
+  patches = [
+    ./CVE-2016-9840.patch
+    ./CVE-2016-9841.patch
+    ./CVE-2016-9842.patch
+    ./CVE-2016-9843.patch
+  ];
+
   postPatch = stdenv.lib.optionalString stdenv.isDarwin ''
     substituteInPlace configure \
       --replace '/usr/bin/libtool' 'ar' \
@@ -81,4 +88,3 @@ stdenv.mkDerivation rec {
     platforms = platforms.all;
   };
 }
-
diff --git a/pkgs/development/python-modules/pandas/default.nix b/pkgs/development/python-modules/pandas/default.nix
new file mode 100644
index 000000000000..a923e553582c
--- /dev/null
+++ b/pkgs/development/python-modules/pandas/default.nix
@@ -0,0 +1,91 @@
+{ buildPythonPackage
+, python
+, stdenv
+, fetchurl
+, nose
+, glibcLocales
+, cython
+, dateutil
+, scipy
+, numexpr
+, pytz
+, xlrd
+, bottleneck
+, sqlalchemy
+, lxml
+, html5lib
+, beautifulsoup4
+, openpyxl
+, tables
+, xlwt
+, darwin ? {}
+, libcxx ? null
+}:
+
+let
+  inherit (stdenv.lib) optional optionalString concatStringsSep;
+  inherit (stdenv) isDarwin;
+in buildPythonPackage rec {
+  pname = "pandas";
+  version = "0.19.2";
+  name = "${pname}-${version}";
+
+  src = fetchurl {
+    url = "mirror://pypi/${builtins.substring 0 1 pname}/${pname}/${name}.tar.gz";
+    sha256 = "6f0f4f598c2b16746803c8bafef7c721c57e4844da752d36240c0acf97658014";
+  };
+
+  LC_ALL = "en_US.UTF-8";
+  buildInputs = [ nose glibcLocales ] ++ optional isDarwin libcxx;
+  propagatedBuildInputs = [
+    cython
+    dateutil
+    scipy
+    numexpr
+    pytz
+    xlrd
+    bottleneck
+    sqlalchemy
+    lxml
+    html5lib
+    beautifulsoup4
+    openpyxl
+    tables
+    xlwt
+  ] ++ optional isDarwin darwin.locale; # provides the locale command
+
+  # For OSX, we need to add a dependency on libcxx, which provides
+  # `complex.h` and other libraries that pandas depends on to build.
+  patchPhase = optionalString isDarwin ''
+    cpp_sdk="${libcxx}/include/c++/v1";
+    echo "Adding $cpp_sdk to the setup.py common_include variable"
+    substituteInPlace setup.py \
+      --replace "['pandas/src/klib', 'pandas/src']" \
+                "['pandas/src/klib', 'pandas/src', '$cpp_sdk']"
+
+  # disable clipboard tests since pbcopy/pbpaste are not open source
+    substituteInPlace pandas/io/tests/test_clipboard.py \
+      --replace pandas.util.clipboard no_such_module \
+      --replace OSError ImportError
+  '';
+
+  # The flag `-A 'not network'` will disable tests that use internet.
+  # The `-e` flag disables a few problematic tests.
+
+  checkPhase = ''
+    runHook preCheck
+    # The flag `-w` provides the initial directory to search for tests.
+    # The flag `-A 'not network'` will disable tests that use internet.
+    nosetests -w $out/${python.sitePackages}/pandas --no-path-adjustment -A 'not slow and not network' --stop \
+      --verbosity=3
+     runHook postCheck
+  '';
+
+  meta = {
+    homepage = "http://pandas.pydata.org/";
+    description = "Python Data Analysis Library";
+    license = stdenv.lib.licenses.bsd3;
+    maintainers = with stdenv.lib.maintainers; [ raskin fridh ];
+    platforms = stdenv.lib.platforms.unix;
+  };
+}
\ No newline at end of file
diff --git a/pkgs/development/python-modules/pycairo/default.nix b/pkgs/development/python-modules/pycairo/default.nix
index 23e06ff4cb4e..e7cf3b4c4489 100644
--- a/pkgs/development/python-modules/pycairo/default.nix
+++ b/pkgs/development/python-modules/pycairo/default.nix
@@ -2,7 +2,7 @@
 
 if (isPyPy) then throw "pycairo not supported for interpreter ${python.executable}" else mkPythonDerivation rec {
   version = "1.10.0";
-  name = "${python.libPrefix}-pycairo-${version}";
+  name = "pycairo-${version}";
   src = if isPy3k
     then fetchurl {
       url = "http://cairographics.org/releases/pycairo-${version}.tar.bz2";
diff --git a/pkgs/development/python-modules/pygame/git.nix b/pkgs/development/python-modules/pygame/git.nix
index 7f815454713d..3140f93aeb40 100644
--- a/pkgs/development/python-modules/pygame/git.nix
+++ b/pkgs/development/python-modules/pygame/git.nix
@@ -41,5 +41,6 @@ buildPythonPackage rec {
     homepage = "http://www.pygame.org/";
     license = licenses.lgpl21Plus;
     platforms = platforms.linux;
+    broken = true;
   };
 }
diff --git a/pkgs/development/python-modules/pytest-expect/default.nix b/pkgs/development/python-modules/pytest-expect/default.nix
new file mode 100644
index 000000000000..5abfd9423ac7
--- /dev/null
+++ b/pkgs/development/python-modules/pytest-expect/default.nix
@@ -0,0 +1,31 @@
+{ buildPythonPackage
+, lib
+, fetchurl
+, pytest
+, u-msgpack-python
+, six
+}:
+
+let
+  pname = "pytest-expect";
+  version = "1.1.0";
+in buildPythonPackage rec {
+  name = "${pname}-${version}";
+
+  src = fetchurl {
+    url = "mirror://pypi/${builtins.substring 0 1 pname}/${pname}/${name}.tar.gz";
+    sha256 = "36b4462704450798197d090809a05f4e13649d9cba9acdc557ce9517da1fd847";
+  };
+
+  buildInputs = [ pytest ];
+  propagatedBuildInputs = [ u-msgpack-python six ];
+
+  # Tests in neither the archive nor the repo
+  doCheck = false;
+
+  meta = {
+    description = "py.test plugin to store test expectations and mark tests based on them";
+    homepage = https://github.com/gsnedders/pytest-expect;
+    license = lib.licenses.mit;
+  };
+}
\ No newline at end of file
diff --git a/pkgs/development/python-modules/u-msgpack-python/default.nix b/pkgs/development/python-modules/u-msgpack-python/default.nix
new file mode 100644
index 000000000000..34d88d74c559
--- /dev/null
+++ b/pkgs/development/python-modules/u-msgpack-python/default.nix
@@ -0,0 +1,33 @@
+{ buildPythonPackage
+, lib
+, fetchurl
+, glibcLocales
+, python
+}:
+
+let
+  pname = "u-msgpack-python";
+  version = "2.3.0";
+in buildPythonPackage rec {
+  name = "${pname}-${version}";
+
+  src = fetchurl {
+    url = "mirror://pypi/${builtins.substring 0 1 pname}/${pname}/${name}.tar.gz";
+    sha256 = "d8df6bb0e2a838aa227c39cfd14aa147ab32b3df6871001874e9b9da9ce1760c";
+  };
+
+  LC_ALL="en_US.UTF-8";
+
+  buildInputs = [ glibcLocales ];
+
+  checkPhase = ''
+    ${python.interpreter} -m unittest discover
+  '';
+
+  meta = {
+    description = "A portable, lightweight MessagePack serializer and deserializer written in pure Python";
+    homepage = https://github.com/vsergeev/u-msgpack-python;
+    license = lib.licenses.mit;
+  };
+
+}
diff --git a/pkgs/development/python-modules/webencodings/default.nix b/pkgs/development/python-modules/webencodings/default.nix
new file mode 100644
index 000000000000..54f3517ca002
--- /dev/null
+++ b/pkgs/development/python-modules/webencodings/default.nix
@@ -0,0 +1,29 @@
+{ buildPythonPackage
+, lib
+, fetchurl
+, pytest
+}:
+
+let
+  pname = "webencodings";
+  version = "0.5";
+in buildPythonPackage rec {
+  name = "${pname}-${version}";
+
+  src = fetchurl {
+    url = "mirror://pypi/${builtins.substring 0 1 pname}/${pname}/${name}.tar.gz";
+    sha256 = "a5c55ee93b24e740fe951c37b5c228dccc1f171450e188555a775261cce1b904";
+  };
+
+  buildInputs = [ pytest ];
+
+  checkPhase = ''
+    py.test webencodings/tests.py
+  '';
+
+  meta = {
+    description = "Character encoding aliases for legacy web content";
+    homepage = https://github.com/SimonSapin/python-webencodings;
+    license = lib.licenses.bsd3;
+  };
+}
\ No newline at end of file
diff --git a/pkgs/development/python-modules/xlwt/default.nix b/pkgs/development/python-modules/xlwt/default.nix
new file mode 100644
index 000000000000..01f920a387ad
--- /dev/null
+++ b/pkgs/development/python-modules/xlwt/default.nix
@@ -0,0 +1,36 @@
+{ buildPythonPackage
+, fetchurl
+, fetchpatch
+, nose
+, lib
+}:
+
+buildPythonPackage rec {
+  pname = "xlwt";
+  name = "${pname}-${version}";
+  version = "1.1.2";
+
+  src = fetchurl {
+    url = "mirror://pypi/${builtins.substring 0 1 pname}/${pname}/${name}.tar.gz";
+    sha256 = "aed648c17731f40f84550dd2a1aaa53569f0cbcaf5610ba895cd2632587b723c";
+  };
+
+  # re.LOCALE was removed in Python 3.6
+  patches = [
+    (fetchpatch {
+      url = "https://github.com/python-excel/xlwt/commit/86564ef26341020316cd8a27c704ef1dc5a6129b.patch";
+      sha256 = "0ifavfld3rrqjb0iyriy4c0drw31gszvlg3nmnn9dmfsh91vxhs6";
+    })
+  ];
+
+  buildInputs = [ nose ];
+  checkPhase = ''
+    nosetests -v
+  '';
+
+  meta = {
+    description = "Library to create spreadsheet files compatible with MS";
+    homepage = https://github.com/python-excel/xlwt;
+    license = with lib.licenses; [ bsdOriginal bsd3 lgpl21 ];
+  };
+}
\ No newline at end of file
diff --git a/pkgs/development/tools/build-managers/cmake/default.nix b/pkgs/development/tools/build-managers/cmake/default.nix
index 1e4bacb07254..fbc6f5be5ca8 100644
--- a/pkgs/development/tools/build-managers/cmake/default.nix
+++ b/pkgs/development/tools/build-managers/cmake/default.nix
@@ -1,5 +1,5 @@
 { stdenv, fetchurl, pkgconfig
-, bzip2, curl, expat, libarchive, xz, zlib
+, bzip2, curl, expat, libarchive, xz, zlib, libuv
 , useNcurses ? false, ncurses, useQt4 ? false, qt4
 , wantPS ? false, ps ? null
 }:
@@ -12,8 +12,8 @@ assert stdenv.cc ? libc;
 
 let
   os = stdenv.lib.optionalString;
-  majorVersion = "3.6";
-  minorVersion = "2";
+  majorVersion = "3.7";
+  minorVersion = "1";
   version = "${majorVersion}.${minorVersion}";
 in
 
@@ -24,7 +24,8 @@ stdenv.mkDerivation rec {
 
   src = fetchurl {
     url = "${meta.homepage}files/v${majorVersion}/cmake-${version}.tar.gz";
-    sha256 = "0imkz04ncz6cv5659qfd4scm99k3siq7zrrsa8pvp663d8mf76hq";
+    # from https://cmake.org/files/v3.7/cmake-3.7.1-SHA-256.txt
+    sha256 = "449a5bce64dbd4d5b9517ebd1a1248ed197add6ad27934478976fd5f1f9330e1";
   };
 
   # Don't search in non-Nix locations such as /usr, but do search in our libc.
@@ -37,7 +38,7 @@ stdenv.mkDerivation rec {
   setupHook = ./setup-hook.sh;
 
   buildInputs =
-    [ setupHook pkgconfig bzip2 curl expat libarchive xz zlib ]
+    [ setupHook pkgconfig bzip2 curl expat libarchive xz zlib libuv ]
     ++ optional useNcurses ncurses
     ++ optional useQt4 qt4;
 
diff --git a/pkgs/development/tools/build-managers/shards/default.nix b/pkgs/development/tools/build-managers/shards/default.nix
new file mode 100644
index 000000000000..7db0d89e8b1f
--- /dev/null
+++ b/pkgs/development/tools/build-managers/shards/default.nix
@@ -0,0 +1,28 @@
+{ stdenv, fetchurl, crystal, libyaml, which }:
+
+stdenv.mkDerivation rec {
+  name = "shards-${version}";
+  version = "0.7.1";
+
+  src = fetchurl {
+    url = "https://github.com/crystal-lang/shards/archive/v${version}.tar.gz";
+    sha256 = "31de819c66518479682ec781a39ef42c157a1a8e6e865544194534e2567cb110";
+  };
+
+  buildInputs = [ crystal libyaml which ];
+
+  buildFlags = [ "CRFLAGS=" "release" ];
+
+  installPhase = ''
+    mkdir -p $out/bin
+    cp bin/shards $out/bin/
+  '';
+
+  meta = with stdenv.lib; {
+    homepage = "https://crystal-lang.org/";
+    license = licenses.asl20;
+    description = "Dependency manager for the Crystal language";
+    maintainers = with maintainers; [ mingchuan ];
+    platforms = [ "x86_64-linux" "i686-linux" "x86_64-darwin" ];
+  };
+}
diff --git a/pkgs/development/tools/continuous-integration/gitlab-runner/default.nix b/pkgs/development/tools/continuous-integration/gitlab-runner/default.nix
index 2a546c8c9073..1338201b9962 100644
--- a/pkgs/development/tools/continuous-integration/gitlab-runner/default.nix
+++ b/pkgs/development/tools/continuous-integration/gitlab-runner/default.nix
@@ -1,16 +1,16 @@
 { lib, buildGoPackage, fetchFromGitLab, fetchurl, go-bindata }:
 
 let
-  version = "1.8.0";
+  version = "1.9.0";
   # Gitlab runner embeds some docker images these are prebuilt for arm and x86_64
   docker_x86_64 = fetchurl {
     url = "https://gitlab-ci-multi-runner-downloads.s3.amazonaws.com/v${version}/docker/prebuilt-x86_64.tar.xz";
-    sha256 = "0fa8hfdxg903n1dqrqbm4069sr8rq6zx7zzybfyj7qz4mmayp24m";
+    sha256 = "12hcpvc0j6g200qhz12gfsslngbqx4sifrikr05vh2av17hba25s";
   };
 
   docker_arm = fetchurl {
     url = "https://gitlab-ci-multi-runner-downloads.s3.amazonaws.com/v${version}/docker/prebuilt-arm.tar.xz";
-    sha256 = "1rvvz34rsjxrgg59rda6v4k8zw16slwprnh4h5b16yhyp7lcx93q";
+    sha256 = "1hqwhg94g514g0ad4h0h7wh7k5clm9i7whzr6c30i8yb00ga628s";
   };
 in
 buildGoPackage rec {
@@ -29,7 +29,7 @@ buildGoPackage rec {
     owner = "gitlab-org";
     repo = "gitlab-ci-multi-runner";
     rev = "v${version}";
-    sha256 = "0svmy2dc4h6jll80y8j2ml7k0a9krknsp9d0zpsfkw3wcz1wfipl";
+    sha256 = "1b30daxnpn1psy3vds1m4mnbl2hmvr2bc0zrd3nn9xm3xacm3dqj";
   };
 
   buildInputs = [ go-bindata ];
@@ -57,7 +57,7 @@ buildGoPackage rec {
   '';
 
   meta = with lib; {
-    description = "GitLab Runner the continous integration executor of GitLab";
+    description = "GitLab Runner the continuous integration executor of GitLab";
     license = licenses.mit;
     homepage = "https://about.gitlab.com/gitlab-ci/";
     platforms = platforms.unix;
diff --git a/pkgs/development/tools/libsigrokdecode/default.nix b/pkgs/development/tools/libsigrokdecode/default.nix
index 706b9bde3273..539a5bd845da 100644
--- a/pkgs/development/tools/libsigrokdecode/default.nix
+++ b/pkgs/development/tools/libsigrokdecode/default.nix
@@ -1,11 +1,11 @@
 { stdenv, fetchurl, pkgconfig, glib, python3, libsigrok, check }:
 
 stdenv.mkDerivation rec {
-  name = "libsigrokdecode-0.4.0";
+  name = "libsigrokdecode-0.4.1";
 
   src = fetchurl {
     url = "http://sigrok.org/download/source/libsigrokdecode/${name}.tar.gz";
-    sha256 = "0drmxjc2xavccjl2i6vcjipijrn7459nv8cpmm788pi4fcdrszpx";
+    sha256 = "15aabl9p4586v2bkj4bm4xi7l3309r9zb31sw233s5vi170p0pq6";
   };
 
   buildInputs = [ pkgconfig glib python3 libsigrok check ];
diff --git a/pkgs/development/tools/misc/cscope/default.nix b/pkgs/development/tools/misc/cscope/default.nix
index 2dff98a212d6..b737bb7a7dab 100644
--- a/pkgs/development/tools/misc/cscope/default.nix
+++ b/pkgs/development/tools/misc/cscope/default.nix
@@ -53,6 +53,6 @@ stdenv.mkDerivation rec {
 
     maintainers = with stdenv.lib.maintainers; [viric];
 
-    platforms = with stdenv.lib.platforms; linux;
+    platforms = stdenv.lib.platforms.unix;
   };
 }
diff --git a/pkgs/development/tools/pypi2nix/default.nix b/pkgs/development/tools/pypi2nix/default.nix
index 229d680f8351..1e6b6690e71b 100644
--- a/pkgs/development/tools/pypi2nix/default.nix
+++ b/pkgs/development/tools/pypi2nix/default.nix
@@ -1,13 +1,13 @@
-{ stdenv, fetchurl, python, zip, makeWrapper
+{ stdenv, fetchurl, python, zip, makeWrapper, nix, nix-prefetch-scripts
 }:
 
 let
 
-  version = "1.5.0";
+  version = "1.6.0";
 
   src = fetchurl {
     url = "https://github.com/garbas/pypi2nix/archive/v${version}.tar.gz";
-    sha256 = "0s79pp7gkgyk7discnv94m6z81fd67p66rdbd4cwk1ma0qljlh2k";
+    sha256 = "08iad1ad2gnvsnd66ddw3lff19ms2yly4iq63c8800j603d0pdhn";
   };
 
   click = fetchurl {
@@ -16,8 +16,8 @@ let
   };
 
   requests = fetchurl {
-    url = "https://pypi.python.org/packages/2e/ad/e627446492cc374c284e82381215dcd9a0a87c4f6e90e9789afefe6da0ad/requests-2.11.1.tar.gz";
-    sha256 = "0cx1w7m4cpslxz9jljxv0l9892ygrrckkiwpp2hangr8b01rikss";
+    url = "https://pypi.python.org/packages/5b/0b/34be574b1ec997247796e5d516f3a6b6509c4e064f2885a96ed885ce7579/requests-2.12.4.tar.gz";
+    sha256 = "0d5fwxmw4ibynk3imph3n4n84m0n3ib1vj339fxhkqri0qd4767d";
   };
 
 in stdenv.mkDerivation rec {
@@ -27,7 +27,7 @@ in stdenv.mkDerivation rec {
     click
     requests
   ];
-  buildInputs = [ python zip makeWrapper ];
+  buildInputs = [ python zip makeWrapper nix.out nix-prefetch-scripts ];
   sourceRoot = ".";
 
   postUnpack = ''
@@ -45,6 +45,11 @@ in stdenv.mkDerivation rec {
     fi
   '';
 
+  patchPhase = ''
+    sed -i -e "s|default='nix-shell',|default='${nix.out}/bin/nix-shell',|" $out/pkgs/pypi2nix/cli.py
+    sed -i -e "s|nix-prefetch-git|${nix-prefetch-scripts}/bin/nix-prefetch-git|" $out/pkgs/pypi2nix/stage2.py
+  '';
+
   commonPhase = ''
     mkdir -p $out/bin