about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2019-05-17 10:56:54 +0000
committerAlyssa Ross <hi@alyssa.is>2019-05-17 10:56:54 +0000
commitc1d22074139ab0d048a05b5e5116265d099114d6 (patch)
tree97977009422d675f8930f97c309b010481289e72 /nixpkgs/pkgs/development/libraries
parent4dc8afe4fd6b18437150129e0a1ecc23c6a1c0b9 (diff)
parentbc9df0f66110039e495b6debe3a6cda4a1bb0fed (diff)
downloadnixlib-c1d22074139ab0d048a05b5e5116265d099114d6.tar
nixlib-c1d22074139ab0d048a05b5e5116265d099114d6.tar.gz
nixlib-c1d22074139ab0d048a05b5e5116265d099114d6.tar.bz2
nixlib-c1d22074139ab0d048a05b5e5116265d099114d6.tar.lz
nixlib-c1d22074139ab0d048a05b5e5116265d099114d6.tar.xz
nixlib-c1d22074139ab0d048a05b5e5116265d099114d6.tar.zst
nixlib-c1d22074139ab0d048a05b5e5116265d099114d6.zip
Merge commit 'bc9df0f66110039e495b6debe3a6cda4a1bb0fed'
Diffstat (limited to 'nixpkgs/pkgs/development/libraries')
-rw-r--r--nixpkgs/pkgs/development/libraries/alkimia/default.nix11
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/libbass/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/rtmidi/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/aws-c-common/default.nix6
-rw-r--r--nixpkgs/pkgs/development/libraries/boost/1.67.nix32
-rw-r--r--nixpkgs/pkgs/development/libraries/boost/generic.nix5
-rw-r--r--nixpkgs/pkgs/development/libraries/bullet/default.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/c-ares/release.patch19
-rw-r--r--nixpkgs/pkgs/development/libraries/cfitsio/default.nix22
-rw-r--r--nixpkgs/pkgs/development/libraries/clucene-core/2.x.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/ctl/default.nix35
-rw-r--r--nixpkgs/pkgs/development/libraries/ctl/source.nix11
-rw-r--r--nixpkgs/pkgs/development/libraries/dav1d/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/eccodes/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/fflas-ffpack/default.nix14
-rw-r--r--nixpkgs/pkgs/development/libraries/ffmpeg-full/default.nix14
-rw-r--r--nixpkgs/pkgs/development/libraries/ffmpeg/4.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/ffmpeg/vpxenc-0.10-libvpx-1.5.patch24
-rw-r--r--nixpkgs/pkgs/development/libraries/ffmpeg/vpxenc-1.2-libvpx-1.5.patch24
-rw-r--r--nixpkgs/pkgs/development/libraries/freetype/disable-pcf-long-family-names.patch15
-rw-r--r--nixpkgs/pkgs/development/libraries/gdk-pixbuf/no-mime-sniffing.patch18
-rw-r--r--nixpkgs/pkgs/development/libraries/gegl/4.0.nix32
-rw-r--r--nixpkgs/pkgs/development/libraries/geos/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/givaro/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/glib/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/glibc/glibc-remove-datetime-from-nscd.patch11
-rw-r--r--nixpkgs/pkgs/development/libraries/gobject-introspection/absolute_shlib_path.patch50
-rw-r--r--nixpkgs/pkgs/development/libraries/gobject-introspection/default.nix5
-rw-r--r--nixpkgs/pkgs/development/libraries/gobject-introspection/macos-shared-library.patch36
-rw-r--r--nixpkgs/pkgs/development/libraries/gobject-introspection/test_shlibs.patch31
-rw-r--r--nixpkgs/pkgs/development/libraries/gpgme/gpgme_libsuffix.patch12
-rw-r--r--nixpkgs/pkgs/development/libraries/gtksourceview/3.x.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/hyperscan/default.nix50
-rw-r--r--nixpkgs/pkgs/development/libraries/java/lombok/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/leptonica/default.nix33
-rw-r--r--nixpkgs/pkgs/development/libraries/libao/default.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/libcdio/default.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/libcroco/default.nix19
-rw-r--r--nixpkgs/pkgs/development/libraries/libdazzle/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/libdrm/default.nix5
-rw-r--r--nixpkgs/pkgs/development/libraries/libdrm/libdrm-apple.patch88
-rw-r--r--nixpkgs/pkgs/development/libraries/libgda/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/libimobiledevice/disable_sslv3.patch25
-rw-r--r--nixpkgs/pkgs/development/libraries/libnsl/cdefs.patch30
-rw-r--r--nixpkgs/pkgs/development/libraries/libnsl/default.nix12
-rw-r--r--nixpkgs/pkgs/development/libraries/libnsl/nis_h.patch45
-rw-r--r--nixpkgs/pkgs/development/libraries/libosinfo/default.nix7
-rw-r--r--nixpkgs/pkgs/development/libraries/libpointmatcher/default.nix21
-rw-r--r--nixpkgs/pkgs/development/libraries/libproxy/default.nix8
-rw-r--r--nixpkgs/pkgs/development/libraries/libressl/default.nix20
-rw-r--r--nixpkgs/pkgs/development/libraries/libseccomp/default.nix6
-rw-r--r--nixpkgs/pkgs/development/libraries/libsnark/darwin-fix-clock-gettime.patch41
-rw-r--r--nixpkgs/pkgs/development/libraries/libsnark/default.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/libsoup/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/libtins/default.nix6
-rw-r--r--nixpkgs/pkgs/development/libraries/libuv/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/libva/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/libxmlb/default.nix6
-rw-r--r--nixpkgs/pkgs/development/libraries/libxslt/default.nix10
-rw-r--r--nixpkgs/pkgs/development/libraries/linbox/default.nix15
-rw-r--r--nixpkgs/pkgs/development/libraries/mesa/darwin-clock-gettime.patch76
-rw-r--r--nixpkgs/pkgs/development/libraries/mesa/default.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/nv-codec-headers/default.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/oniguruma/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/opencsg/default.nix35
-rw-r--r--nixpkgs/pkgs/development/libraries/opencsg/fix-pro-files.patch21
-rw-r--r--nixpkgs/pkgs/development/libraries/openexr/default.nix26
-rw-r--r--nixpkgs/pkgs/development/libraries/physics/rivet/key_val.patch12
-rw-r--r--nixpkgs/pkgs/development/libraries/physics/rivet/zaxis_fix.patch42
-rw-r--r--nixpkgs/pkgs/development/libraries/polkit/default.nix38
-rw-r--r--nixpkgs/pkgs/development/libraries/portaudio/default.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/qscintilla/default.nix10
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-4.x/4.8/default.nix1
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/default.nix32
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin-nseventtype.patch13
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin-revert-69221.patch73
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin.patch70
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-revert-no-macos10.10.patch102
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-clang-fix.patch30
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-darwin-old-sdk.patch21
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-darwin-sdk-10.10.patch160
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebkit-darwin-no-qos-classes.patch11
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebkit-darwin-no-readline.patch45
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.12/default.nix12
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-darwin-nseventtype.patch13
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-darwin.patch70
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-revert-no-macos10.10.patch102
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.9/default.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/5.9/qtbase-darwin.patch35
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/modules/qtbase.nix36
-rw-r--r--nixpkgs/pkgs/development/libraries/qt-5/modules/qtwebengine.nix2
-rw-r--r--nixpkgs/pkgs/development/libraries/range-v3/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/science/math/fenics/default.nix9
-rw-r--r--nixpkgs/pkgs/development/libraries/science/math/openblas/default.nix1
-rw-r--r--nixpkgs/pkgs/development/libraries/sqlite/analyzer.nix6
-rw-r--r--nixpkgs/pkgs/development/libraries/sqlite/default.nix8
-rw-r--r--nixpkgs/pkgs/development/libraries/tbb/default.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/tk/8.6.nix4
-rw-r--r--nixpkgs/pkgs/development/libraries/tk/generic.nix11
-rw-r--r--nixpkgs/pkgs/development/libraries/v8/build-standalone-static-library.patch14
-rw-r--r--nixpkgs/pkgs/development/libraries/v8/disable-building-tests.patch27
-rw-r--r--nixpkgs/pkgs/development/libraries/v8/fPIC-for-static.patch13
-rw-r--r--nixpkgs/pkgs/development/libraries/wxwidgets/2.9/default.nix3
-rw-r--r--nixpkgs/pkgs/development/libraries/wxwidgets/3.0/default.nix1
-rw-r--r--nixpkgs/pkgs/development/libraries/wxwidgets/3.0/mac.nix1
105 files changed, 426 insertions, 1724 deletions
diff --git a/nixpkgs/pkgs/development/libraries/alkimia/default.nix b/nixpkgs/pkgs/development/libraries/alkimia/default.nix
index 6f4fd09015e5..f98c8fa480e1 100644
--- a/nixpkgs/pkgs/development/libraries/alkimia/default.nix
+++ b/nixpkgs/pkgs/development/libraries/alkimia/default.nix
@@ -1,19 +1,20 @@
 { mkDerivation, fetchurl, lib
-, extra-cmake-modules, doxygen, graphviz, qtbase, mpir
+, extra-cmake-modules, doxygen, graphviz, qtbase, qtwebkit, mpir
+, kdelibs4support, plasma-framework, knewstuff, kpackage
 }:
 
 mkDerivation rec {
   name = "alkimia-${version}";
-  version = "7.0.1";
+  version = "8.0.1";
 
   src = fetchurl {
-    url = "mirror://kde/stable/alkimia/${version}/src/${name}.tar.xz";
-    sha256 = "1fri76465058fgsyrmdrc3hj1javz4g10mfzqp5rsj7qncjr1i22";
+    url = "mirror://kde/stable/alkimia/${version}/${name}.tar.xz";
+    sha256 = "059i6vn36sdq5zn2vqzh4asvvgdgs7n478nk9phvb5gdys01fq7m";
   };
 
   nativeBuildInputs = [ extra-cmake-modules doxygen graphviz ];
 
-  buildInputs = [ qtbase ];
+  buildInputs = [ qtbase qtwebkit kdelibs4support plasma-framework knewstuff kpackage ];
   propagatedBuildInputs = [ mpir ];
 
   meta = {
diff --git a/nixpkgs/pkgs/development/libraries/audio/libbass/default.nix b/nixpkgs/pkgs/development/libraries/audio/libbass/default.nix
index 390ca6bb04b7..0e1445ca9ee1 100644
--- a/nixpkgs/pkgs/development/libraries/audio/libbass/default.nix
+++ b/nixpkgs/pkgs/development/libraries/audio/libbass/default.nix
@@ -11,7 +11,7 @@ let
         x86_64-linux = "x64/libbass.so";
       };
       urlpath = "bass${version}-linux.zip";
-      sha256 = "0alxx7knkvzwwifqrmzavafwq53flja7s1ckaabk6p2ir2f0j5cp";
+      sha256 = "1hjxp1akj8367qlglv5rqpwq2dimfz3bkllwq39abavz4sp8smjz";
     };
 
     bass_fx = {
@@ -21,7 +21,7 @@ let
         x86_64-linux = "x64/libbass_fx.so";
       };
       urlpath = "z/0/bass_fx${version}-linux.zip";
-      sha256 = "0j1cbq88j3vnqf2bibcqnfhciz904w48ldgycyh9d8954hwyg22m";
+      sha256 = "1q0g74z7iyhxqps5b3gnnbic8v2jji1r0mkvais57lsx8y21sbin";
     };
   };
 
diff --git a/nixpkgs/pkgs/development/libraries/audio/rtmidi/default.nix b/nixpkgs/pkgs/development/libraries/audio/rtmidi/default.nix
index 0f3f1fce42b0..41bb9ca9f11b 100644
--- a/nixpkgs/pkgs/development/libraries/audio/rtmidi/default.nix
+++ b/nixpkgs/pkgs/development/libraries/audio/rtmidi/default.nix
@@ -1,14 +1,14 @@
 { stdenv, fetchFromGitHub, autoconf, automake, libtool, libjack2, alsaLib, pkgconfig }:
 
 stdenv.mkDerivation rec {
-  version = "2.1.1";
+  version = "4.0.0";
   name = "rtmidi-${version}";
 
   src = fetchFromGitHub {
     owner = "thestk";
     repo = "rtmidi";
     rev = "${version}";
-    sha256 = "11pl45lp8sq5xkpipwk622w508nw0qcxr03ibicqn1lsws0hva96";
+    sha256 = "1g31p6a96djlbk9jh5r4pjly3x76lhccva9hrw6xzdma8dsjzgyq";
   };
 
   enableParallelBuilding = true;
diff --git a/nixpkgs/pkgs/development/libraries/aws-c-common/default.nix b/nixpkgs/pkgs/development/libraries/aws-c-common/default.nix
index 5b938ddb03cf..c8f284acc135 100644
--- a/nixpkgs/pkgs/development/libraries/aws-c-common/default.nix
+++ b/nixpkgs/pkgs/development/libraries/aws-c-common/default.nix
@@ -2,19 +2,17 @@
 
 stdenv.mkDerivation rec {
   pname = "aws-c-common";
-  version = "0.3.4";
+  version = "0.3.9";
 
   src = fetchFromGitHub {
     owner = "awslabs";
     repo = pname;
     rev = "v${version}";
-    sha256 = "1z02ndb9jjn0p5bcc49pq0d8c0q2pq33dlszw77l76jkhrfx0921";
+    sha256 = "04wrmrw83vypqzsq88b2q8kp5sfbv0qsci3bcxw0c2mfxqk8358n";
   };
 
   nativeBuildInputs = [ cmake ];
 
-  buildInputs = lib.optional stdenv.hostPlatform.isMusl libexecinfo;
-
   NIX_CFLAGS_COMPILE = lib.optionals stdenv.isDarwin [
     "-Wno-nullability-extension"
     "-Wno-typedef-redefinition"
diff --git a/nixpkgs/pkgs/development/libraries/boost/1.67.nix b/nixpkgs/pkgs/development/libraries/boost/1.67.nix
index 938892ef3554..406e63b9622b 100644
--- a/nixpkgs/pkgs/development/libraries/boost/1.67.nix
+++ b/nixpkgs/pkgs/development/libraries/boost/1.67.nix
@@ -3,11 +3,33 @@
 callPackage ./generic.nix (args // rec {
   version = "1.67.0";
 
-  patches = [ (fetchpatch {
-    url = "https://github.com/boostorg/lockfree/commit/12726cda009a855073b9bedbdce57b6ce7763da2.patch";
-    sha256 = "0x65nkwzv8fdacj8sw5njl3v63jj19dirrpklbwy6qpsncw7fc7h";
-    stripLen = 1;
-  })];
+  patches = [
+    (fetchpatch {
+      url = "https://github.com/boostorg/lockfree/commit/12726cda009a855073b9bedbdce57b6ce7763da2.patch";
+      sha256 = "0x65nkwzv8fdacj8sw5njl3v63jj19dirrpklbwy6qpsncw7fc7h";
+      stripLen = 1;
+    })
+  ] ++ stdenv.lib.optionals stdenv.cc.isClang [
+    # Fixes https://github.com/boostorg/atomic/issues/15
+    (fetchpatch {
+      url = https://github.com/boostorg/atomic/commit/6e14ca24dab50ad4c1fa8c27c7dd6f1cb791b534.patch;
+      sha256 = "102g35ygvv8cxagp9651284xk4vybk93q2fm577y4mdxf5k46b7a";
+      stripLen = 1;
+    })
+
+    # Needed for the next patch
+    (fetchpatch {
+      url = https://github.com/boostorg/asio/commit/38cb19719748ad56b14d73ca1fff5828f36e5894.patch;
+      sha256 = "0cj9cxz9rfbsx8p8f5alxx00dq3r7g0vh23j68bbxbs9gq1arq2n";
+      stripLen = 1;
+    })
+    # Fixes https://github.com/boostorg/asio/pull/91
+    (fetchpatch {
+      url = https://github.com/boostorg/asio/commit/43874d5497414c67655d901e48c939ef01337edb.patch;
+      sha256 = "1c2ds164s2ygvpb4785p4ncv8ywbpm08cphirb99xp4mqvb693is";
+      stripLen = 1;
+    })
+  ];
 
   src = fetchurl {
     url = "mirror://sourceforge/boost/boost_1_67_0.tar.bz2";
diff --git a/nixpkgs/pkgs/development/libraries/boost/generic.nix b/nixpkgs/pkgs/development/libraries/boost/generic.nix
index 8ce44b878d07..c0c69b0fe70a 100644
--- a/nixpkgs/pkgs/development/libraries/boost/generic.nix
+++ b/nixpkgs/pkgs/development/libraries/boost/generic.nix
@@ -114,8 +114,9 @@ stdenv.mkDerivation {
     description = "Collection of C++ libraries";
     license = stdenv.lib.licenses.boost;
 
-    platforms = (platforms.unix ++ platforms.windows);
-    badPlatforms = stdenv.lib.optional (versionOlder version "1.59") "aarch64-linux";
+    platforms = platforms.unix ++ platforms.windows;
+    badPlatforms = stdenv.lib.optional (versionOlder version "1.59") "aarch64-linux"
+                 ++ stdenv.lib.optional ((versionOlder version "1.57") || version == "1.58") "x86_64-darwin";
     maintainers = with maintainers; [ peti ];
   };
 
diff --git a/nixpkgs/pkgs/development/libraries/bullet/default.nix b/nixpkgs/pkgs/development/libraries/bullet/default.nix
index fca5e8d70a3b..b4a2133f7d8f 100644
--- a/nixpkgs/pkgs/development/libraries/bullet/default.nix
+++ b/nixpkgs/pkgs/development/libraries/bullet/default.nix
@@ -40,6 +40,8 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
+  NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.cc.isClang "-Wno-error=argument-outside-range";
+
   meta = with stdenv.lib; {
     description = "A professional free 3D Game Multiphysics Library";
     longDescription = ''
diff --git a/nixpkgs/pkgs/development/libraries/c-ares/release.patch b/nixpkgs/pkgs/development/libraries/c-ares/release.patch
deleted file mode 100644
index e745648062a5..000000000000
--- a/nixpkgs/pkgs/development/libraries/c-ares/release.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-diff -aur c-ares-cares-1_13_0/ares_version.h c-ares-1.13.0/ares_version.h
---- c-ares-cares-1_13_0/ares_version.h	2017-06-20 02:00:21.000000000 -0400
-+++ c-ares-1.13.0/ares_version.h	2017-06-20 02:03:54.000000000 -0400
-@@ -6,12 +6,12 @@
- #define ARES_COPYRIGHT "2004 - 2016 Daniel Stenberg, <daniel@haxx.se>."
- 
- #define ARES_VERSION_MAJOR 1
--#define ARES_VERSION_MINOR 12
--#define ARES_VERSION_PATCH 1
-+#define ARES_VERSION_MINOR 13
-+#define ARES_VERSION_PATCH 0
- #define ARES_VERSION ((ARES_VERSION_MAJOR<<16)|\
-                        (ARES_VERSION_MINOR<<8)|\
-                        (ARES_VERSION_PATCH))
--#define ARES_VERSION_STR "1.12.1-DEV"
-+#define ARES_VERSION_STR "1.13.0"
- 
- #if (ARES_VERSION >= 0x010700)
- #  define CARES_HAVE_ARES_LIBRARY_INIT 1
diff --git a/nixpkgs/pkgs/development/libraries/cfitsio/default.nix b/nixpkgs/pkgs/development/libraries/cfitsio/default.nix
index a21158723be1..32308c34ead1 100644
--- a/nixpkgs/pkgs/development/libraries/cfitsio/default.nix
+++ b/nixpkgs/pkgs/development/libraries/cfitsio/default.nix
@@ -1,15 +1,23 @@
-{ fetchurl, stdenv }:
+{ fetchurl, stdenv
 
- stdenv.mkDerivation {
-  name = "cfitsio-3.430";
+# Optional dependencies
+, bzip2 ? null }:
+
+stdenv.mkDerivation rec {
+  name = "cfitsio-${version}";
+  version = "3.450";
 
   src = fetchurl {
-    url = "ftp://heasarc.gsfc.nasa.gov/software/fitsio/c/cfitsio3430.tar.gz";
-    sha256 = "07fghxh5fl8nqk3q0dh8rvc83npnm0hisxzcj16a6r7gj5pmp40l";
+    url = "https://heasarc.gsfc.nasa.gov/FTP/software/fitsio/c/cfitsio${builtins.replaceStrings ["."] [""] version}.tar.gz";
+    sha256 = "0bmrkw6w65zb0k3mszaaqy1f4zjm2hl7njww74nb5v38wvdi4q5z";
   };
 
+  buildInputs = [ bzip2 ];
+
   patches = [ ./darwin-curl-config.patch ./darwin-rpath-universal.patch ];
 
+  configureFlags = stdenv.lib.optional (bzip2 != null) "--with-bzip2=${bzip2.out}";
+
   # Shared-only build
   buildFlags = "shared";
   postPatch = '' sed -e '/^install:/s/libcfitsio.a //' -e 's@/bin/@@g' -i Makefile.in
@@ -27,8 +35,8 @@
          advanced features for manipulating and filtering the information in
          FITS files.
       '';
-    # Permissive BSD-style license.
-    license = "permissive";
+    license = licenses.mit;
+    maintainers = [ maintainers.xbreak ];
     platforms = with platforms; linux ++ darwin;
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/clucene-core/2.x.nix b/nixpkgs/pkgs/development/libraries/clucene-core/2.x.nix
index 6eb310550bcd..91347813a24f 100644
--- a/nixpkgs/pkgs/development/libraries/clucene-core/2.x.nix
+++ b/nixpkgs/pkgs/development/libraries/clucene-core/2.x.nix
@@ -36,6 +36,8 @@ stdenv.mkDerivation rec {
   # /build/clucene-core-2.3.3.4/build/bin/cl_test"
   doCheck = false;
 
+  NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.cc.isClang "-Wno-error=c++11-narrowing";
+
   meta = with stdenv.lib; {
     description = "Core library for full-featured text search engine";
     longDescription = ''
diff --git a/nixpkgs/pkgs/development/libraries/ctl/default.nix b/nixpkgs/pkgs/development/libraries/ctl/default.nix
index ac6c9657dde6..71e301044766 100644
--- a/nixpkgs/pkgs/development/libraries/ctl/default.nix
+++ b/nixpkgs/pkgs/development/libraries/ctl/default.nix
@@ -1,22 +1,31 @@
-{ stdenv, callPackage, cmake, pkgconfig, ilmbase, libtiff, openexr }:
+{ stdenv, fetchFromGitHub, fetchpatch, cmake, pkgconfig, ilmbase, libtiff, openexr }:
 
-let
-  source = callPackage ./source.nix { };
-in
-stdenv.mkDerivation {
-  name = "ctl-${source.version}";
+stdenv.mkDerivation rec {
+  pname = "ctl";
+  version = "1.5.2";
 
-  src = source.src;
+  src = fetchFromGitHub {
+    owner = "ampas";
+    repo = pname;
+    rev = "${pname}-${version}";
+    sha256 = "0a698rd1cmixh3mk4r1xa6rjli8b8b7dbx89pb43xkgqxy67glwx";
+  };
+
+  patches = [
+    (fetchpatch {
+      name = "ctl-1.5.2-ilm_230.patch";
+      url = "https://src.fedoraproject.org/rpms/CTL/raw/9d7c15a91bccdc0a9485d463bf2789be72e6b17d/f/ctl-1.5.2-ilm_230.patch";
+      sha256 = "0mdx7llwrm0q8ai53zhyxi40i9h5s339dbkqpqv30yzi2xpnfj3d";
+    })
+  ];
 
-  nativeBuildInputs = [ pkgconfig ];
-  buildInputs = [ cmake libtiff ilmbase openexr ];
+  nativeBuildInputs = [ cmake pkgconfig ];
+  buildInputs = [ libtiff ilmbase openexr ];
 
   meta = with stdenv.lib; {
     description = "Color Transformation Language";
-    homepage = http://ampasctl.sourceforge.net;
-    license = "A.M.P.A.S";
+    homepage = "https://github.com/ampas/CTL";
+    license = "A.M.P.A.S"; # BSD-derivative, free but GPL incompatible
     platforms = platforms.all;
   };
-
-  passthru.source = source;
 }
diff --git a/nixpkgs/pkgs/development/libraries/ctl/source.nix b/nixpkgs/pkgs/development/libraries/ctl/source.nix
deleted file mode 100644
index d0cb83c0369f..000000000000
--- a/nixpkgs/pkgs/development/libraries/ctl/source.nix
+++ /dev/null
@@ -1,11 +0,0 @@
-{ fetchFromGitHub }:
-rec {
-  version = "1.5.2";
-
-  src = fetchFromGitHub {
-    owner = "ampas";
-    repo = "CTL";
-    rev = "ctl-${version}";
-    sha256 = "0a698rd1cmixh3mk4r1xa6rjli8b8b7dbx89pb43xkgqxy67glwx";
-  };
-}
diff --git a/nixpkgs/pkgs/development/libraries/dav1d/default.nix b/nixpkgs/pkgs/development/libraries/dav1d/default.nix
index 49536687a931..157a6a21f3de 100644
--- a/nixpkgs/pkgs/development/libraries/dav1d/default.nix
+++ b/nixpkgs/pkgs/development/libraries/dav1d/default.nix
@@ -2,14 +2,14 @@
 
 stdenv.mkDerivation rec {
   pname = "dav1d";
-  version = "0.3.0";
+  version = "0.3.1";
 
   src = fetchFromGitLab {
     domain = "code.videolan.org";
     owner = "videolan";
     repo = pname;
     rev = version;
-    sha256 = "08vysa3naqjfvld9w1k6l6hby4xfn4l2gvnfnan498g5nss4050h";
+    sha256 = "1m5vdg64iqxpi37l84mcfiq313g9z55zf66s85j2rqik6asmxbqg";
   };
 
   nativeBuildInputs = [ meson ninja nasm ];
diff --git a/nixpkgs/pkgs/development/libraries/eccodes/default.nix b/nixpkgs/pkgs/development/libraries/eccodes/default.nix
index 4eaded814366..78f80d2baf42 100644
--- a/nixpkgs/pkgs/development/libraries/eccodes/default.nix
+++ b/nixpkgs/pkgs/development/libraries/eccodes/default.nix
@@ -6,11 +6,11 @@
 with stdenv.lib;
 stdenv.mkDerivation rec {
   name = "eccodes-${version}";
-  version = "2.12.0";
+  version = "2.12.5";
 
   src = fetchurl {
     url = "https://confluence.ecmwf.int/download/attachments/45757960/eccodes-${version}-Source.tar.gz";
-    sha256 = "0rqkx6p85b0v6zdkm4q2r516b7ldkxhkfc0cwkl24djlkv7fanpp";
+    sha256 = "0576fccng4nvmq5gma1nb1v00if5cwl81w4nv5zkb80q5wicn50c";
   };
 
   postPatch = ''
diff --git a/nixpkgs/pkgs/development/libraries/fflas-ffpack/default.nix b/nixpkgs/pkgs/development/libraries/fflas-ffpack/default.nix
index a37a11f5cb0c..a67210e860cd 100644
--- a/nixpkgs/pkgs/development/libraries/fflas-ffpack/default.nix
+++ b/nixpkgs/pkgs/development/libraries/fflas-ffpack/default.nix
@@ -1,28 +1,18 @@
 { stdenv, fetchFromGitHub, autoreconfHook, givaro, pkgconfig, blas
-, fetchpatch
 , gmpxx
 }:
 stdenv.mkDerivation rec {
   name = "${pname}-${version}";
   pname = "fflas-ffpack";
-  version = "2.3.2";
+  version = "2.4.0";
 
   src = fetchFromGitHub {
     owner = "linbox-team";
     repo = "${pname}";
     rev = "v${version}";
-    sha256 = "1cqhassj2dny3gx0iywvmnpq8ca0d6m82xl5rz4mb8gaxr2kwddl";
+    sha256 = "1q1ala88ysz14pb5cn2kskv829nc1qif7zfzjwzhd5nnzwyivmc4";
   };
 
-  patches = [
-    # https://github.com/linbox-team/fflas-ffpack/issues/146
-    (fetchpatch {
-      name = "fix-flaky-test-fgemm-check.patch";
-      url = "https://github.com/linbox-team/fflas-ffpack/commit/d8cd67d91a9535417a5cb193cf1540ad6758a3db.patch";
-      sha256 = "1gnfc616fvnlr0smvz6lb2d445vn8fgv6vqcr6pwm3dj4wa6v3b3";
-    })
-  ];
-
   checkInputs = [
     gmpxx
   ];
diff --git a/nixpkgs/pkgs/development/libraries/ffmpeg-full/default.nix b/nixpkgs/pkgs/development/libraries/ffmpeg-full/default.nix
index 306b4e22cfc9..db606cc02d63 100644
--- a/nixpkgs/pkgs/development/libraries/ffmpeg-full/default.nix
+++ b/nixpkgs/pkgs/development/libraries/ffmpeg-full/default.nix
@@ -97,8 +97,7 @@
 , libXv ? null # Xlib support
 , libXext ? null # Xlib support
 , lzma ? null # xz-utils
-, nvenc ? false, nvidia-video-sdk ? null, nv-codec-headers ? null # NVIDIA NVENC support
-, callPackage # needed for NVENC to access external ffmpeg nvidia headers
+, nvenc ? true, nv-codec-headers ? null # NVIDIA NVENC support
 , openal ? null # OpenAL 1.1 capture support
 #, opencl ? null # OpenCL code
 , opencore-amr ? null # AMR-NB de/encoder & AMR-WB decoder
@@ -228,15 +227,14 @@ assert libxcbxfixesExtlib -> libxcb != null;
 assert libxcbshapeExtlib -> libxcb != null;
 assert openglExtlib -> libGLU_combined != null;
 assert opensslExtlib -> gnutls == null && openssl != null && nonfreeLicensing;
-assert nvenc -> nvidia-video-sdk != null && nonfreeLicensing;
 
 stdenv.mkDerivation rec {
   name = "ffmpeg-full-${version}";
-  version = "4.1.2";
+  version = "4.1.3";
 
   src = fetchurl {
     url = "https://www.ffmpeg.org/releases/ffmpeg-${version}.tar.xz";
-    sha256 = "0yrl6nij4b1pk1c4nbi80857dsd760gziiss2ls19awq8zj0lpxr";
+    sha256 = "0gdnprc7gk4b7ckq8wbxbrj7i00r76r9a5g9mj7iln40512j0c0c";
   };
 
   prePatch = ''
@@ -418,13 +416,13 @@ stdenv.mkDerivation rec {
     ++ optional ((isLinux || isFreeBSD) && libva != null) libva
     ++ optionals isLinux [ alsaLib libraw1394 libv4l ]
     ++ optional (isLinux && libmfx != null) libmfx
-    ++ optionals nvenc [ nvidia-video-sdk nv-codec-headers ]
+    ++ optional nvenc nv-codec-headers
     ++ optionals stdenv.isDarwin [ Cocoa CoreServices CoreAudio AVFoundation
                                    MediaToolbox VideoDecodeAcceleration
                                    libiconv cf-private /* For _OBJC_EHTYPE_$_NSException */ ];
 
-  # Build qt-faststart executable
-  buildPhase = optional qtFaststartProgram ''make tools/qt-faststart'';
+  buildFlags = [ "all" ]
+    ++ optional qtFaststartProgram "tools/qt-faststart"; # Build qt-faststart executable
 
   # Hacky framework patching technique borrowed from the phantomjs2 package
   postInstall = optionalString qtFaststartProgram ''
diff --git a/nixpkgs/pkgs/development/libraries/ffmpeg/4.nix b/nixpkgs/pkgs/development/libraries/ffmpeg/4.nix
index 7e2507d5afdf..3066e0b12e58 100644
--- a/nixpkgs/pkgs/development/libraries/ffmpeg/4.nix
+++ b/nixpkgs/pkgs/development/libraries/ffmpeg/4.nix
@@ -6,7 +6,7 @@
 
 callPackage ./generic.nix (args // rec {
   version = "${branch}";
-  branch = "4.1.2";
-  sha256 = "00yzwc2g97h8ws0haz1p0ahaavhgrbha6xjdc53a5vyfy3zyy3i0";
+  branch = "4.1.3";
+  sha256 = "0aka5pibjhpks1wrsvqpy98v8cbvyvnngwqhh4ajkg6pbdl7k9i9";
   darwinFrameworks = [ Cocoa CoreMedia VideoToolbox ];
 })
diff --git a/nixpkgs/pkgs/development/libraries/ffmpeg/vpxenc-0.10-libvpx-1.5.patch b/nixpkgs/pkgs/development/libraries/ffmpeg/vpxenc-0.10-libvpx-1.5.patch
deleted file mode 100644
index 740bb746aade..000000000000
--- a/nixpkgs/pkgs/development/libraries/ffmpeg/vpxenc-0.10-libvpx-1.5.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-diff --git a/libavcodec/libvpxenc.c b/libavcodec/libvpxenc.c
-index 1d33ce9..dface51 100644
---- a/libavcodec/libvpxenc.c
-+++ b/libavcodec/libvpxenc.c
-@@ -78,19 +78,11 @@ typedef struct VP8EncoderContext {
- 
- /** String mappings for enum vp8e_enc_control_id */
- static const char *ctlidstr[] = {
--    [VP8E_UPD_ENTROPY]           = "VP8E_UPD_ENTROPY",
--    [VP8E_UPD_REFERENCE]         = "VP8E_UPD_REFERENCE",
--    [VP8E_USE_REFERENCE]         = "VP8E_USE_REFERENCE",
--    [VP8E_SET_ROI_MAP]           = "VP8E_SET_ROI_MAP",
--    [VP8E_SET_ACTIVEMAP]         = "VP8E_SET_ACTIVEMAP",
--    [VP8E_SET_SCALEMODE]         = "VP8E_SET_SCALEMODE",
-     [VP8E_SET_CPUUSED]           = "VP8E_SET_CPUUSED",
-     [VP8E_SET_ENABLEAUTOALTREF]  = "VP8E_SET_ENABLEAUTOALTREF",
-     [VP8E_SET_NOISE_SENSITIVITY] = "VP8E_SET_NOISE_SENSITIVITY",
--    [VP8E_SET_SHARPNESS]         = "VP8E_SET_SHARPNESS",
-     [VP8E_SET_STATIC_THRESHOLD]  = "VP8E_SET_STATIC_THRESHOLD",
-     [VP8E_SET_TOKEN_PARTITIONS]  = "VP8E_SET_TOKEN_PARTITIONS",
--    [VP8E_GET_LAST_QUANTIZER]    = "VP8E_GET_LAST_QUANTIZER",
-     [VP8E_SET_ARNR_MAXFRAMES]    = "VP8E_SET_ARNR_MAXFRAMES",
-     [VP8E_SET_ARNR_STRENGTH]     = "VP8E_SET_ARNR_STRENGTH",
-     [VP8E_SET_ARNR_TYPE]         = "VP8E_SET_ARNR_TYPE",
diff --git a/nixpkgs/pkgs/development/libraries/ffmpeg/vpxenc-1.2-libvpx-1.5.patch b/nixpkgs/pkgs/development/libraries/ffmpeg/vpxenc-1.2-libvpx-1.5.patch
deleted file mode 100644
index 7f1ec1df6c76..000000000000
--- a/nixpkgs/pkgs/development/libraries/ffmpeg/vpxenc-1.2-libvpx-1.5.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-diff --git a/libavcodec/libvpxenc.c b/libavcodec/libvpxenc.c
-index 4f1adb8..1791952 100644
---- a/libavcodec/libvpxenc.c
-+++ b/libavcodec/libvpxenc.c
-@@ -87,19 +87,11 @@ typedef struct VP8EncoderContext {
- 
- /** String mappings for enum vp8e_enc_control_id */
- static const char *const ctlidstr[] = {
--    [VP8E_UPD_ENTROPY]           = "VP8E_UPD_ENTROPY",
--    [VP8E_UPD_REFERENCE]         = "VP8E_UPD_REFERENCE",
--    [VP8E_USE_REFERENCE]         = "VP8E_USE_REFERENCE",
--    [VP8E_SET_ROI_MAP]           = "VP8E_SET_ROI_MAP",
--    [VP8E_SET_ACTIVEMAP]         = "VP8E_SET_ACTIVEMAP",
--    [VP8E_SET_SCALEMODE]         = "VP8E_SET_SCALEMODE",
-     [VP8E_SET_CPUUSED]           = "VP8E_SET_CPUUSED",
-     [VP8E_SET_ENABLEAUTOALTREF]  = "VP8E_SET_ENABLEAUTOALTREF",
-     [VP8E_SET_NOISE_SENSITIVITY] = "VP8E_SET_NOISE_SENSITIVITY",
--    [VP8E_SET_SHARPNESS]         = "VP8E_SET_SHARPNESS",
-     [VP8E_SET_STATIC_THRESHOLD]  = "VP8E_SET_STATIC_THRESHOLD",
-     [VP8E_SET_TOKEN_PARTITIONS]  = "VP8E_SET_TOKEN_PARTITIONS",
--    [VP8E_GET_LAST_QUANTIZER]    = "VP8E_GET_LAST_QUANTIZER",
-     [VP8E_SET_ARNR_MAXFRAMES]    = "VP8E_SET_ARNR_MAXFRAMES",
-     [VP8E_SET_ARNR_STRENGTH]     = "VP8E_SET_ARNR_STRENGTH",
-     [VP8E_SET_ARNR_TYPE]         = "VP8E_SET_ARNR_TYPE",
diff --git a/nixpkgs/pkgs/development/libraries/freetype/disable-pcf-long-family-names.patch b/nixpkgs/pkgs/development/libraries/freetype/disable-pcf-long-family-names.patch
deleted file mode 100644
index e3dfe4aabd60..000000000000
--- a/nixpkgs/pkgs/development/libraries/freetype/disable-pcf-long-family-names.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-diff --git a/include/freetype/config/ftoption.h b/include/freetype/config/ftoption.h
-index 5676074..37a0d00 100644
---- a/include/freetype/config/ftoption.h
-+++ b/include/freetype/config/ftoption.h
-@@ -856,7 +856,7 @@ FT_BEGIN_HEADER
-   /* If this option is activated, it can be controlled with the            */
-   /* `no-long-family-names' property of the pcf driver module.             */
-   /*                                                                       */
--#define PCF_CONFIG_OPTION_LONG_FAMILY_NAMES
-+/* #define PCF_CONFIG_OPTION_LONG_FAMILY_NAMES */
- 
- 
-   /*************************************************************************/
--- 
-cgit v1.0-41-gc330
\ No newline at end of file
diff --git a/nixpkgs/pkgs/development/libraries/gdk-pixbuf/no-mime-sniffing.patch b/nixpkgs/pkgs/development/libraries/gdk-pixbuf/no-mime-sniffing.patch
deleted file mode 100644
index 9896e25acda1..000000000000
--- a/nixpkgs/pkgs/development/libraries/gdk-pixbuf/no-mime-sniffing.patch
+++ /dev/null
@@ -1,18 +0,0 @@
---- a/meson.build
-+++ b/meson.build
-@@ -186,13 +186,8 @@
- gmodule_dep = dependency('gmodule-no-export-2.0')
- gio_dep = dependency('gio-2.0')
- 
--# On non-Windows/macOS systems we always required shared-mime-info and GIO
--if host_system != 'windows' and host_system != 'darwin'
--  shared_mime_dep = dependency('shared-mime-info')
--  gdk_pixbuf_conf.set('GDK_PIXBUF_USE_GIO_MIME', 1)
--else
--  shared_mime_dep = []
--endif
-+# No MIME sniffing for now
-+shared_mime_dep = []
- 
- gdk_pixbuf_deps = [ mathlib_dep, gobject_dep, gmodule_dep, gio_dep, shared_mime_dep ]
- 
diff --git a/nixpkgs/pkgs/development/libraries/gegl/4.0.nix b/nixpkgs/pkgs/development/libraries/gegl/4.0.nix
index da20438fb4bb..4215f0ebc30d 100644
--- a/nixpkgs/pkgs/development/libraries/gegl/4.0.nix
+++ b/nixpkgs/pkgs/development/libraries/gegl/4.0.nix
@@ -1,45 +1,19 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig, glib, babl, libpng, cairo, libjpeg, which
+{ stdenv, fetchurl, pkgconfig, glib, babl, libpng, cairo, libjpeg, which
 , librsvg, pango, gtk, bzip2, json-glib, gettext, autoreconfHook, libraw
 , gexiv2, libwebp, gnome3, libintl }:
 
 stdenv.mkDerivation rec {
   pname = "gegl";
-  version = "0.4.14";
+  version = "0.4.16";
 
   outputs = [ "out" "dev" "devdoc" ];
   outputBin = "dev";
 
   src = fetchurl {
     url = "https://download.gimp.org/pub/gegl/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2";
-    sha256 = "00crhngwi07f5b9x77kx5p7p4cl6l5g6glpz9rqv7pfqk62xa0ac";
+    sha256 = "0njydcr6qdmfzh4fxx544681qxdpf7y6b2f47jcypn810dlxy4h1";
   };
 
-  patches = stdenv.lib.optionals stdenv.isDarwin [
-    # Make the Darwin patches below apply cleanly
-    (fetchpatch {
-      url = https://gitlab.gnome.org/GNOME/gegl/commit/141a7aa76cd36143f624f06b1c43d2483945653c.patch;
-      sha256 = "0ijv9ra6723jn60krjwzbc6l9qr08h76bsz9xgddvfgsgr1nnpbi";
-    })
-    (fetchpatch {
-      url = https://gitlab.gnome.org/GNOME/gegl/commit/b3ff0df080d133bbdb394c3db40d4f9d2980a8a6.patch;
-      sha256 = "0im0rqk8mz9vi7qqx06vj4wm5hjwv1544jwdaaywlcrs9g266hl0";
-    })
-    (fetchpatch {
-      url = https://gitlab.gnome.org/GNOME/gegl/commit/fe756be6f0c776a45201a61f67d3e5e42f6398de.patch;
-      sha256 = "0h3rqwfsph2gisbwvc2v5a9r5b0djcxlm790xpi6yfndj42b0v2b";
-    })
-    # Fix build on Darwin
-    # https://gitlab.gnome.org/GNOME/gegl/merge_requests/28
-    (fetchpatch {
-      url = https://gitlab.gnome.org/GNOME/gegl/commit/ac331b5c0e3d940b64bb811b0f54e86c7d312917.patch;
-      sha256 = "1yj9jh8q9cbr1szrxhdapknk4nfhbkbc1njv50ifrj7vyfislj34";
-    })
-    (fetchpatch {
-      url = https://gitlab.gnome.org/GNOME/gegl/commit/d05eb01170728f45f561ca937708a293e29e02d9.patch;
-      sha256 = "0gwz12sm8kkmzyxsiq0sl30cabs5q0ckj743yrzimspkhrvc1ya2";
-    })
-  ];
-
   enableParallelBuilding = true;
 
   doCheck = true;
diff --git a/nixpkgs/pkgs/development/libraries/geos/default.nix b/nixpkgs/pkgs/development/libraries/geos/default.nix
index d857c9931fe9..ae8d88d12d9e 100644
--- a/nixpkgs/pkgs/development/libraries/geos/default.nix
+++ b/nixpkgs/pkgs/development/libraries/geos/default.nix
@@ -1,11 +1,11 @@
 { stdenv, fetchurl, python }:
 
 stdenv.mkDerivation rec {
-  name = "geos-3.7.1";
+  name = "geos-3.7.2";
 
   src = fetchurl {
     url = "https://download.osgeo.org/geos/${name}.tar.bz2";
-    sha256 = "1312m02xk4sp6f1xdpb9w0ic0zbxg90p5y66qnwidl5fksscf1h0";
+    sha256 = "01vpkncvq1i1191agq03yg1h7d0igj10gv5z2mqk24nnwrdycri1";
   };
 
   enableParallelBuilding = true;
diff --git a/nixpkgs/pkgs/development/libraries/givaro/default.nix b/nixpkgs/pkgs/development/libraries/givaro/default.nix
index bfbce57b0a6a..0221b9c70133 100644
--- a/nixpkgs/pkgs/development/libraries/givaro/default.nix
+++ b/nixpkgs/pkgs/development/libraries/givaro/default.nix
@@ -2,12 +2,12 @@
 stdenv.mkDerivation rec {
   name = "${pname}-${version}";
   pname = "givaro";
-  version = "4.0.4";
+  version = "4.1.0";
   src = fetchFromGitHub {
     owner = "linbox-team";
     repo = "${pname}";
     rev = "v${version}";
-    sha256 = "199p8wyj5i63jbnk7j8qbdbfp5rm2lpmcxyk3mdjy9bz7ygx3hhy";
+    sha256 = "1l1172c964hni66mjdmhr7766l5k7y63zs3hgcpr10a8f1nx3iwp";
   };
 
   enableParallelBuilding = true;
diff --git a/nixpkgs/pkgs/development/libraries/glib/default.nix b/nixpkgs/pkgs/development/libraries/glib/default.nix
index 05a52dce0f99..95eaf37d5c73 100644
--- a/nixpkgs/pkgs/development/libraries/glib/default.nix
+++ b/nixpkgs/pkgs/development/libraries/glib/default.nix
@@ -46,7 +46,7 @@ let
   '';
 
   binPrograms = optional (!stdenv.isDarwin) "gapplication" ++ [ "gdbus" "gio" "gsettings" ];
-  version = "2.60.0";
+  version = "2.60.1";
 in
 
 stdenv.mkDerivation rec {
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
 
   src = fetchurl {
     url = "mirror://gnome/sources/glib/${stdenv.lib.versions.majorMinor version}/${name}.tar.xz";
-    sha256 = "0ls3njqknb345ni5i8hn9nr1n70kn6s8bi0g6kcqj3c4js5mv1i0";
+    sha256 = "0q2mkdvp20v6dvrhik8k5j875kj29hcfz346xi0624n6spsq9y49";
   };
 
   patches = optional stdenv.isDarwin ./darwin-compilation.patch
diff --git a/nixpkgs/pkgs/development/libraries/glibc/glibc-remove-datetime-from-nscd.patch b/nixpkgs/pkgs/development/libraries/glibc/glibc-remove-datetime-from-nscd.patch
deleted file mode 100644
index db010e62366b..000000000000
--- a/nixpkgs/pkgs/development/libraries/glibc/glibc-remove-datetime-from-nscd.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/nscd/nscd_stat.c
-+++ b/nscd/nscd_stat.c
-@@ -37,7 +37,7 @@
- 
- 
- /* We use this to make sure the receiver is the same.  */
--static const char compilation[21] = __DATE__ " " __TIME__;
-+static const char compilation[] = "@out@";
- 
- /* Statistic data for one database.  */
- struct dbstat
diff --git a/nixpkgs/pkgs/development/libraries/gobject-introspection/absolute_shlib_path.patch b/nixpkgs/pkgs/development/libraries/gobject-introspection/absolute_shlib_path.patch
index e2525d833f8f..6e56d3fab411 100644
--- a/nixpkgs/pkgs/development/libraries/gobject-introspection/absolute_shlib_path.patch
+++ b/nixpkgs/pkgs/development/libraries/gobject-introspection/absolute_shlib_path.patch
@@ -1,6 +1,6 @@
 --- a/giscanner/scannermain.py
 +++ b/giscanner/scannermain.py
-@@ -101,6 +101,39 @@
+@@ -95,6 +95,39 @@ def get_windows_option_group(parser):
      return group
  
  
@@ -40,7 +40,7 @@
  def _get_option_parser():
      parser = optparse.OptionParser('%prog [options] sources',
                                     version='%prog ' + giscanner.__version__)
-@@ -211,6 +244,10 @@
+@@ -205,6 +238,10 @@ match the namespace prefix.""")
      parser.add_option("", "--filelist",
                        action="store", dest="filelist", default=[],
                        help="file containing headers and sources to be scanned")
@@ -53,7 +53,7 @@
      parser.add_option_group(group)
 --- a/giscanner/shlibs.py
 +++ b/giscanner/shlibs.py
-@@ -62,6 +62,12 @@
+@@ -57,6 +57,12 @@ def _ldd_library_pattern(library_name):
      $""" % re.escape(library_name), re.VERBOSE)
  
  
@@ -66,21 +66,33 @@
  # This is a what we do for non-la files. We assume that we are on an
  # ELF-like system where ldd exists and the soname extracted with ldd is
  # a filename that can be opened with dlopen().
-@@ -110,17 +116,16 @@ def _resolve_non_libtool(options, binary, libraries):
-         if isinstance(output, bytes):
+@@ -106,7 +112,8 @@ def _resolve_non_libtool(options, binary, libraries):
              output = output.decode("utf-8", "replace")
  
--        # Use absolute paths on OS X to conform to how libraries are usually
--        # referenced on OS X systems, and file names everywhere else.
--        basename = platform.system() != 'Darwin'
--        return resolve_from_ldd_output(libraries, output, basename=basename)
-+        # Never strip away absolute paths in Nix
-+        basename = False
-+        return resolve_from_ldd_output(libraries, output, basename=basename, fallback_libpath=options.fallback_libpath)
+         shlibs = resolve_from_ldd_output(libraries, output)
+-        return list(map(sanitize_shlib_path, shlibs))
++        fallback_libpath = options.fallback_libpath or "";
++        return list(map(lambda p: os.path.join(fallback_libpath, p), map(sanitize_shlib_path, shlibs)))
  
  
--def resolve_from_ldd_output(libraries, output, basename=False):
-+def resolve_from_ldd_output(libraries, output, basename=False, fallback_libpath=""):
+ def sanitize_shlib_path(lib):
+@@ -115,19 +122,18 @@ def sanitize_shlib_path(lib):
+     # In case we get relative paths on macOS (like @rpath) then we fall
+     # back to the basename as well:
+     # https://gitlab.gnome.org/GNOME/gobject-introspection/issues/222
+-    if sys.platform == "darwin":
+-        if not os.path.isabs(lib):
+-            return os.path.basename(lib)
+-        return lib
+-    else:
++
++    # Always use absolute paths if available
++    if not os.path.isabs(lib):
+         return os.path.basename(lib)
++    return lib
+ 
+ 
+ def resolve_from_ldd_output(libraries, output):
      patterns = {}
      for library in libraries:
          if not os.path.isfile(library):
@@ -89,7 +101,7 @@
      if len(patterns) == 0:
          return []
  
-@@ -129,11 +134,14 @@ def resolve_from_ldd_output(libraries, output, basename=False):
+@@ -139,8 +145,11 @@ def resolve_from_ldd_output(libraries, output):
          if line.endswith(':'):
              continue
          for word in line.split():
@@ -102,14 +114,10 @@
 +                    m = pattern.match(word)
                  if m:
                      del patterns[library]
--                    shlibs.append(_sanitize_install_name(m.group()))
-+                    shlibs.append(os.path.join(fallback_libpath, _sanitize_install_name(m.group())))
-                     break
- 
-     if len(patterns) > 0:
+                     shlibs.append(m.group())
 --- a/giscanner/utils.py
 +++ b/giscanner/utils.py
-@@ -116,17 +116,11 @@
+@@ -111,17 +111,11 @@ def extract_libtool_shlib(la_file):
      if dlname is None:
          return None
  
diff --git a/nixpkgs/pkgs/development/libraries/gobject-introspection/default.nix b/nixpkgs/pkgs/development/libraries/gobject-introspection/default.nix
index e6978d0955fb..26c472930ed5 100644
--- a/nixpkgs/pkgs/development/libraries/gobject-introspection/default.nix
+++ b/nixpkgs/pkgs/development/libraries/gobject-introspection/default.nix
@@ -9,7 +9,7 @@
 
 let
   pname = "gobject-introspection";
-  version = "1.60.0";
+  version = "1.60.1";
 in
 with stdenv.lib;
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   src = fetchurl {
     url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${name}.tar.xz";
-    sha256 = "0pgk9lcvz3i79m6g2ynlp00ghws7g0p0d5qyf0k72warrf841zly";
+    sha256 = "1cr4r3lh5alrks9q2ycs1kn2crnkhrhn2wrmibng6dndkr4x2i6q";
   };
 
   outputs = [ "out" "dev" "man" ];
@@ -40,7 +40,6 @@ stdenv.mkDerivation rec {
   setupHook = ./setup-hook.sh;
 
   patches = [
-    ./macos-shared-library.patch
     (substituteAll {
       src = ./test_shlibs.patch;
       inherit nixStoreDir;
diff --git a/nixpkgs/pkgs/development/libraries/gobject-introspection/macos-shared-library.patch b/nixpkgs/pkgs/development/libraries/gobject-introspection/macos-shared-library.patch
deleted file mode 100644
index 9941878c427b..000000000000
--- a/nixpkgs/pkgs/development/libraries/gobject-introspection/macos-shared-library.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-diff --git a/giscanner/shlibs.py b/giscanner/shlibs.py
-index c93d20c..4d4915d 100644
---- a/giscanner/shlibs.py
-+++ b/giscanner/shlibs.py
-@@ -43,6 +43,22 @@ def _resolve_libtool(options, binary, libraries):
- 
-     return shlibs
- 
-+def _sanitize_install_name(install_name):
-+    '''
-+    On macOS, the dylib can be built with install_name as @rpath/libfoo.so
-+    instead of the absolute path to the library, so handle that. The name
-+    can also be @loader_path or @executable_path.
-+    '''
-+    if not install_name.startswith('@'):
-+        return install_name
-+    if install_name.startswith('@rpath/'):
-+        return install_name[7:]
-+    if install_name.startswith('@loader_path/'):
-+        return install_name[13:]
-+    if install_name.startswith('@executable_path/'):
-+        return install_name[17:]
-+    raise RuntimeError('Unknown install_name {!r}'.format(install_name))
-+
- 
- # Assume ldd output is something vaguely like
- #
-@@ -136,7 +152,7 @@ def resolve_from_ldd_output(libraries, output, basename=False):
-                 m = pattern.match(word)
-                 if m:
-                     del patterns[library]
--                    shlibs.append(m.group())
-+                    shlibs.append(_sanitize_install_name(m.group()))
-                     break
- 
-     if len(patterns) > 0:
diff --git a/nixpkgs/pkgs/development/libraries/gobject-introspection/test_shlibs.patch b/nixpkgs/pkgs/development/libraries/gobject-introspection/test_shlibs.patch
index c3152982d199..65b5a1a13b91 100644
--- a/nixpkgs/pkgs/development/libraries/gobject-introspection/test_shlibs.patch
+++ b/nixpkgs/pkgs/development/libraries/gobject-introspection/test_shlibs.patch
@@ -1,6 +1,6 @@
 --- a/tests/scanner/test_shlibs.py
 +++ b/tests/scanner/test_shlibs.py
-@@ -10,6 +10,46 @@ from giscanner.shlibs import resolve_from_ldd_output
+@@ -7,6 +7,30 @@ from giscanner.shlibs import resolve_from_ldd_output, sanitize_shlib_path
  
  class TestLddParser(unittest.TestCase):
  
@@ -26,25 +26,18 @@
 +        self.assertEqual(
 +            ['@nixStoreDir@/gmrf09y7sfxrr0mcx90dba7w41jj2kzk-glib-2.58.1/lib/libglib-2.0.so.0',
 +             '@nixStoreDir@/gmrf09y7sfxrr0mcx90dba7w41jj2kzk-glib-2.58.1/lib/libgio-2.0.so.0'],
-+            resolve_from_ldd_output(libraries, output, basename=False))
-+
-+    def test_resolve_from_ldd_output_macos(self):
-+        output = '''\
-+            @rpath/libatk-1.0.0.dylib
-+            @rpath/libgstreamer-1.0.0.dylib (compatibility version 0.0.0, current version 0.0.0)
-+            /Volumes/USB_SSD/cerbero/build/dist/darwin_x86_64/lib/libglib-2.0.0.dylib (compatibility version 0.0.0, current version 0.0.0)
-+            /Volumes/USB_SSD/cerbero/build/dist/darwin_x86_64/lib/libintl.dylib (compatibility version 0.0.0, current version 0.0.0)
-+            /Volumes/USB_SSD/cerbero/build/dist/darwin_x86_64/lib/libgobject-2.0.0.dylib (compatibility version 0.0.0, current version 0.0.0)
-+            /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1252.50.4)
-+        '''
-+        libraries = ['atk-1.0']
-+        fallback_libpath = '@nixStoreDir@/1ynd5b01z87c1nw75k5iy7sq49hpkw53-atk-2.30.0/lib'
-+
-+        self.assertEqual(
-+            [ '%s/libatk-1.0.0.dylib' % fallback_libpath ],
-+            resolve_from_ldd_output(libraries, output, basename=False, fallback_libpath=fallback_libpath))
++            resolve_from_ldd_output(libraries, output))
 +
      def test_resolve_from_ldd_output(self):
          output = '''\
              libglib-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007fbe12d68000)
-
+@@ -40,7 +64,8 @@ class TestLddParser(unittest.TestCase):
+ 
+         self.assertEqual(
+             sanitize_shlib_path('/foo/bar'),
+-            '/foo/bar' if sys.platform == 'darwin' else 'bar')
++            # NixOS always want the absolute path
++            '/foo/bar')
+ 
+     def test_unresolved_library(self):
+         output = ''
diff --git a/nixpkgs/pkgs/development/libraries/gpgme/gpgme_libsuffix.patch b/nixpkgs/pkgs/development/libraries/gpgme/gpgme_libsuffix.patch
deleted file mode 100644
index 4abc2757cf6f..000000000000
--- a/nixpkgs/pkgs/development/libraries/gpgme/gpgme_libsuffix.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff --git a/lang/cpp/src/GpgmeppConfig.cmake.in.in b/lang/cpp/src/GpgmeppConfig.cmake.in.in
-index 928d19f..cbe9713 100644 (file)
---- a/lang/cpp/src/GpgmeppConfig.cmake.in.in
-+++ b/lang/cpp/src/GpgmeppConfig.cmake.in.in
-@@ -63,7 +63,7 @@ add_library(Gpgmepp SHARED IMPORTED)
- 
- set_target_properties(Gpgmepp PROPERTIES
-   INTERFACE_INCLUDE_DIRECTORIES "@resolved_includedir@/gpgme++;@resolved_includedir@"
--  INTERFACE_LINK_LIBRARIES "pthread;@resolved_libdir@/libgpgme@libsuffix@;@LIBASSUAN_LIBS@"
-+  INTERFACE_LINK_LIBRARIES "pthread;@resolved_libdir@/libgpgme.so;@LIBASSUAN_LIBS@"
-   IMPORTED_LOCATION "@resolved_libdir@/libgpgmepp.so"
- )
diff --git a/nixpkgs/pkgs/development/libraries/gtksourceview/3.x.nix b/nixpkgs/pkgs/development/libraries/gtksourceview/3.x.nix
index 0f72afe4cc15..9d1751afaf91 100644
--- a/nixpkgs/pkgs/development/libraries/gtksourceview/3.x.nix
+++ b/nixpkgs/pkgs/development/libraries/gtksourceview/3.x.nix
@@ -3,11 +3,11 @@
 
 stdenv.mkDerivation rec {
   name = "gtksourceview-${version}";
-  version = "3.24.10";
+  version = "3.24.11";
 
   src = fetchurl {
     url = "mirror://gnome/sources/gtksourceview/${stdenv.lib.versions.majorMinor version}/${name}.tar.xz";
-    sha256 = "16ym7jwiki4s1pilwr4incx0yg7ll94f1cajrnpndkxxs36hcm5b";
+    sha256 = "1zbpj283b5ycz767hqz5kdq02wzsga65pp4fykvhg8xj6x50f6v9";
   };
 
   propagatedBuildInputs = [
diff --git a/nixpkgs/pkgs/development/libraries/hyperscan/default.nix b/nixpkgs/pkgs/development/libraries/hyperscan/default.nix
index 53a3210caca8..bc0ce15a083d 100644
--- a/nixpkgs/pkgs/development/libraries/hyperscan/default.nix
+++ b/nixpkgs/pkgs/development/libraries/hyperscan/default.nix
@@ -1,5 +1,7 @@
-{ lib, stdenv, fetchFromGitHub, cmake, ragel, python27
+{ stdenv, fetchFromGitHub, cmake, ragel, python3
+, coreutils, gnused, utillinux
 , boost
+, withStatic ? false # build only shared libs by default, build static+shared if true
 }:
 
 # NOTICE: pkgconfig, pcap and pcre intentionally omitted from build inputs
@@ -8,45 +10,41 @@
 #         I not see any reason (for now) to backport 8.41.
 
 stdenv.mkDerivation rec {
-  name = "${pname}-${version}";
   pname = "hyperscan";
-  version = "5.1.0";
+  version = "5.1.1";
 
   src = fetchFromGitHub {
     owner = "intel";
-    repo = "hyperscan";
-    sha256 = "0r2c7s7alnq14yhbfhpkq6m28a3pyfqd427115k0754afxi82vbq";
+    repo = pname;
+    sha256 = "11adkz5ln2d2jywwlmixfnwqp5wxskq1104hmmcpws590lhkjv6j";
     rev = "v${version}";
   };
 
   outputs = [ "out" "dev" ];
 
   buildInputs = [ boost ];
-  nativeBuildInputs = [ cmake ragel python27 ];
+  nativeBuildInputs = [
+    cmake ragel python3
+    # Consider simply using busybox for these
+    # Need at least: rev, sed, cut, nm
+    coreutils gnused utillinux
+  ];
 
   cmakeFlags = [
     "-DFAT_RUNTIME=ON"
     "-DBUILD_AVX512=ON"
-    "-DBUILD_STATIC_AND_SHARED=ON"
-  ];
+  ]
+  ++ stdenv.lib.optional (withStatic) "-DBUILD_STATIC_AND_SHARED=ON"
+  ++ stdenv.lib.optional (!withStatic) "-DBUILD_SHARED_LIBS=ON";
 
-  prePatch = ''
+  postPatch = ''
     sed -i '/examples/d' CMakeLists.txt
+    substituteInPlace libhs.pc.in \
+      --replace "libdir=@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_LIBDIR@" "libdir=@CMAKE_INSTALL_LIBDIR@" \
+      --replace "includedir=@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_INCLUDEDIR@" "includedir=@CMAKE_INSTALL_INCLUDEDIR@"
   '';
 
-  postInstall = ''
-    mkdir -p $dev/lib
-    mv $out/lib/*.a $dev/lib/
-    ln -sf $out/lib/libhs.so $dev/lib/
-    ln -sf $out/lib/libhs_runtime.so $dev/lib/
-  '';
-
-  postFixup = ''
-    sed -i "s,$out/include,$dev/include," $dev/lib/pkgconfig/libhs.pc
-    sed -i "s,$out/lib,$dev/lib," $dev/lib/pkgconfig/libhs.pc
-  '';
-
-  meta = {
+  meta = with stdenv.lib; {
     description = "High-performance multiple regex matching library";
     longDescription = ''
       Hyperscan is a high-performance multiple regex matching library.
@@ -61,9 +59,9 @@ stdenv.mkDerivation rec {
       Hyperscan is typically used in a DPI library stack.
     '';
 
-    homepage = https://www.hyperscan.io/;
-    maintainers = with lib.maintainers; [ avnik ];
-    platforms = [ "x86_64-linux" "x86_64-darwin" ];
-    license = lib.licenses.bsd3;
+    homepage = "https://www.hyperscan.io/";
+    maintainers = with maintainers; [ avnik ];
+    platforms = [ "x86_64-linux" ]; # can't find nm on darwin ; might build on aarch64 but untested
+    license = licenses.bsd3;
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/java/lombok/default.nix b/nixpkgs/pkgs/development/libraries/java/lombok/default.nix
index 7f932d52dc41..be3ddfff4c84 100644
--- a/nixpkgs/pkgs/development/libraries/java/lombok/default.nix
+++ b/nixpkgs/pkgs/development/libraries/java/lombok/default.nix
@@ -1,11 +1,11 @@
 { stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
-  name = "lombok-1.18.4";
+  name = "lombok-1.18.8";
 
   src = fetchurl {
     url = "https://projectlombok.org/downloads/${name}.jar";
-    sha256 = "0hlpycnmzd71ihn59hzf445dvwky2lkv57jimx91i6v7xcnr5wrr";
+    sha256 = "1z14rc3fh03qvn2xkjrb7ha0hddv3f3vsp781xm336sp4cl9b5h3";
   };
 
   buildCommand = ''
diff --git a/nixpkgs/pkgs/development/libraries/leptonica/default.nix b/nixpkgs/pkgs/development/libraries/leptonica/default.nix
index b9b6c3c7c24f..52d835d7a206 100644
--- a/nixpkgs/pkgs/development/libraries/leptonica/default.nix
+++ b/nixpkgs/pkgs/development/libraries/leptonica/default.nix
@@ -1,44 +1,27 @@
-{ stdenv, fetchurl, fetchpatch, autoreconfHook, pkgconfig
+{ stdenv, fetchurl, fetchpatch, autoreconfHook, pkgconfig, which, gnuplot
 , giflib, libjpeg, libpng, libtiff, libwebp, openjpeg, zlib
 }:
 
 stdenv.mkDerivation rec {
   name = "leptonica-${version}";
-  version = "1.74.1";
+  version = "1.78.0";
 
   src = fetchurl {
     url = "http://www.leptonica.org/source/${name}.tar.gz";
-    sha256 = "0qpcidvv6igybrrhj0m6j47g642c8sk1qn4dpj82mgd38xx52skl";
+    sha256 = "122s9b8hi93va4lgwnwrbma50x5fp740npy0s92xybd2wy0jxvg2";
   };
 
-  patches = stdenv.lib.singleton (fetchpatch {
-    # configure: Support pkg-config
-    url = "https://github.com/DanBloomberg/leptonica/commit/"
-        + "4476d162cc191a0fefb2ce434153e12bbf188664.patch";
-    sha256 = "1razzp2g49shfaravfqpxm3ivcd1r92lvqysll6nnf6d1wp9865s";
-  });
-
-  postPatch = ''
-    # Remove the AC_SUBST() macros on *_LIBS, because the *_LIBS variables will
-    # be automatically set by PKG_CHECK_MODULES() since autotools 0.24 and
-    # using the ones that are set here in Leptonica's configure.ac do not
-    # include -L linker flags.
-    sed -i -e '/PKG_CHECK_MODULES/,/^ *\])/s/AC_SUBST([^)]*)//' configure.ac
-
-    # The giflib package doesn't ship a pkg-config file, so we need to inject
-    # the linker search path.
-    substituteInPlace configure.ac --replace -lgif \
-      ${stdenv.lib.escapeShellArg "'-L${giflib}/lib -lgif'"}
-  '';
-
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ giflib libjpeg libpng libtiff libwebp openjpeg zlib ];
+  enableParallelBuilding = true;
+
+  checkInputs = [ which gnuplot ];
+  doCheck = !stdenv.isDarwin;
 
   meta = {
     description = "Image processing and analysis library";
     homepage = http://www.leptonica.org/;
-    # Its own license: http://www.leptonica.org/about-the-license.html
-    license = stdenv.lib.licenses.free;
+    license = stdenv.lib.licenses.bsd2; # http://www.leptonica.org/about-the-license.html
     platforms = stdenv.lib.platforms.unix;
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/libao/default.nix b/nixpkgs/pkgs/development/libraries/libao/default.nix
index 826f72b1f5fb..c1cf3215c16c 100644
--- a/nixpkgs/pkgs/development/libraries/libao/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libao/default.nix
@@ -1,5 +1,5 @@
 { stdenv, lib, fetchFromGitHub, autoreconfHook, pkgconfig, libpulseaudio, alsaLib, libcap
-, CoreAudio, CoreServices, AudioUnit
+, CoreAudio, CoreServices, AudioUnit, AudioToolbox
 , usePulseAudio }:
 
 stdenv.mkDerivation rec {
diff --git a/nixpkgs/pkgs/development/libraries/libcdio/default.nix b/nixpkgs/pkgs/development/libraries/libcdio/default.nix
index 5c50d093243c..531ca4102afe 100644
--- a/nixpkgs/pkgs/development/libraries/libcdio/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libcdio/default.nix
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libcddb ncurses help2man ]
     ++ stdenv.lib.optionals stdenv.isDarwin [ libiconv Carbon IOKit ];
 
-  doCheck = true;
+  doCheck = !stdenv.isDarwin;
 
   meta = with stdenv.lib; {
     description = "A library for OS-independent CD-ROM and CD image access";
diff --git a/nixpkgs/pkgs/development/libraries/libcroco/default.nix b/nixpkgs/pkgs/development/libraries/libcroco/default.nix
index dc4a967e7ac6..90ed8c6d985d 100644
--- a/nixpkgs/pkgs/development/libraries/libcroco/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libcroco/default.nix
@@ -1,27 +1,14 @@
-{ stdenv, fetchurl, pkgconfig, libxml2, glib, fetchpatch, gnome3 }:
+{ stdenv, fetchurl, pkgconfig, libxml2, glib, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "libcroco";
-  version = "0.6.12";
+  version = "0.6.13";
 
   src = fetchurl {
     url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
-    sha256 = "0q7qhi7z64i26zabg9dbs5706fa8pmzp1qhpa052id4zdiabbi6x";
+    sha256 = "1m110rbj5d2raxcdp4iz0qp172284945awrsbdlq99ksmqsc4zkn";
   };
 
-  patches = [
-    (fetchpatch {
-      name = "CVE-2017-7960.patch";
-      url = https://gitlab.gnome.org/GNOME/libcroco/commit/898e3a8c8c0314d2e6b106809a8e3e93cf9d4394.patch;
-      sha256 = "1xjwdqijxf4b7mhdp3kkgnb6c14y0bn3b3gg79kyrm82x696d94l";
-    })
-    (fetchpatch {
-      name = "CVE-2017-7961.patch";
-      url = https://gitlab.gnome.org/GNOME/libcroco/commit/9ad72875e9f08e4c519ef63d44cdbd94aa9504f7.patch;
-      sha256 = "0zakd72ynzjgzskwyvqglqiznsb93j1bkvc1lgyrzgv9rwrbwv9s";
-    })
-  ];
-
   outputs = [ "out" "dev" ];
   outputBin = "dev";
 
diff --git a/nixpkgs/pkgs/development/libraries/libdazzle/default.nix b/nixpkgs/pkgs/development/libraries/libdazzle/default.nix
index 59f07202fde2..28d9152dcee7 100644
--- a/nixpkgs/pkgs/development/libraries/libdazzle/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libdazzle/default.nix
@@ -2,7 +2,7 @@
 , gtk-doc, docbook_xsl, docbook_xml_dtd_43, glibcLocales, dbus, xvfb_run, glib, gtk3, gnome3 }:
 
 let
-  version = "3.32.1";
+  version = "3.32.2";
   pname = "libdazzle";
 in
 stdenv.mkDerivation {
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
 
   src = fetchurl {
     url = "mirror://gnome/sources/libdazzle/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
-    sha256 = "0wprqgn480r31pcgmpyk9l6cfvlczfcx10fpqaq9pbn3vjgs3393";
+    sha256 = "0hgi7gnkna9n42nh7p81crrw0jjj22yr8acych60wxh6hzxqsgs1";
   };
 
   nativeBuildInputs = [ ninja meson pkgconfig vala gobject-introspection libxml2 gtk-doc docbook_xsl docbook_xml_dtd_43 glibcLocales dbus xvfb_run ];
diff --git a/nixpkgs/pkgs/development/libraries/libdrm/default.nix b/nixpkgs/pkgs/development/libraries/libdrm/default.nix
index a0bd7d864548..a8daf5754165 100644
--- a/nixpkgs/pkgs/development/libraries/libdrm/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libdrm/default.nix
@@ -14,17 +14,12 @@ stdenv.mkDerivation rec {
   buildInputs = [ libpthreadstubs libpciaccess valgrind-light ];
     # libdrm as of 2.4.70 does not actually do anything with udev.
 
-  patches = stdenv.lib.optional stdenv.isDarwin ./libdrm-apple.patch;
-
   postPatch = ''
     for a in */*-symbol-check ; do
       patchShebangs $a
     done
   '';
 
-  preConfigure = stdenv.lib.optionalString stdenv.isDarwin
-    "echo : \\\${ac_cv_func_clock_gettime=\'yes\'} > config.cache";
-
   configureFlags = [ "--enable-install-test-programs" ]
     ++ stdenv.lib.optionals (stdenv.isAarch32 || stdenv.isAarch64)
       [ "--enable-tegra-experimental-api" "--enable-etnaviv-experimental-api" ]
diff --git a/nixpkgs/pkgs/development/libraries/libdrm/libdrm-apple.patch b/nixpkgs/pkgs/development/libraries/libdrm/libdrm-apple.patch
deleted file mode 100644
index 17b447789c2f..000000000000
--- a/nixpkgs/pkgs/development/libraries/libdrm/libdrm-apple.patch
+++ /dev/null
@@ -1,88 +0,0 @@
-diff -Naur libdrm-2.4.26-orig/intel/intel_bufmgr_gem.c libdrm-2.4.26/intel/intel_bufmgr_gem.c
---- libdrm-2.4.26-orig/intel/intel_bufmgr_gem.c	2011-04-01 10:30:51.000000000 -0400
-+++ libdrm-2.4.26/intel/intel_bufmgr_gem.c	2011-08-29 02:17:20.000000000 -0400
-@@ -51,6 +51,7 @@
- #include <sys/stat.h>
- #include <sys/types.h>
- #include <stdbool.h>
-+#include <sys/time.h>
- 
- #include "errno.h"
- #include "libdrm_lists.h"
-@@ -987,9 +988,9 @@
- 	if (atomic_dec_and_test(&bo_gem->refcount)) {
- 		drm_intel_bufmgr_gem *bufmgr_gem =
- 		    (drm_intel_bufmgr_gem *) bo->bufmgr;
--		struct timespec time;
-+		struct timeval time;
- 
--		clock_gettime(CLOCK_MONOTONIC, &time);
-+		gettimeofday(&time, NULL);
- 
- 		pthread_mutex_lock(&bufmgr_gem->lock);
- 		drm_intel_gem_bo_unreference_final(bo, time.tv_sec);
-diff -Naur libdrm-2.4.26-orig/xf86drm.c libdrm-2.4.26/xf86drm.c
---- libdrm-2.4.26-orig/xf86drm.c	2011-03-21 09:39:24.000000000 -0400
-+++ libdrm-2.4.26/xf86drm.c	2011-08-29 02:17:49.000000000 -0400
-@@ -51,6 +51,9 @@
- #include <sys/mman.h>
- #include <sys/time.h>
- #include <stdarg.h>
-+#if defined(__APPLE__) && defined(__MACH__)
-+#include <mach/mach_time.h>
-+#endif
- 
- /* Not all systems have MAP_FAILED defined */
- #ifndef MAP_FAILED
-@@ -1941,20 +1944,43 @@
-  */
- int drmWaitVBlank(int fd, drmVBlankPtr vbl)
- {
-+#if defined(__APPLE__) && defined(__MACH__)
-+    uint64_t start, end, elapsed, elapsedNano;
-+    static const uint64_t maxElapsed = 2000000000;
-+    static mach_timebase_info_data_t timebaseInfo;
-+    if ( timebaseInfo.denom == 0 ) {
-+	(void) mach_timebase_info(&timebaseInfo);
-+    }
-+#else
-     struct timespec timeout, cur;
-+#endif
-     int ret;
- 
-+#if defined(__APPLE__) && defined(__MACH__)
-+    start = mach_absolute_time();
-+#else
-     ret = clock_gettime(CLOCK_MONOTONIC, &timeout);
-     if (ret < 0) {
- 	fprintf(stderr, "clock_gettime failed: %s\n", strerror(ret));
- 	goto out;
-     }
-     timeout.tv_sec++;
-+#endif
- 
-     do {
-        ret = ioctl(fd, DRM_IOCTL_WAIT_VBLANK, vbl);
-        vbl->request.type &= ~DRM_VBLANK_RELATIVE;
-        if (ret && errno == EINTR) {
-+#if defined(__APPLE__) && defined(__MACH__)
-+	       end = mach_absolute_time();
-+	       elapsed = end - start;
-+	       elapsedNano = elapsed * timebaseInfo.numer / timebaseInfo.denom;
-+	       if (elapsedNano > maxElapsed) {
-+		   errno = EBUSY;
-+		   ret = -1;
-+		   break;
-+	       }
-+#else
- 	       clock_gettime(CLOCK_MONOTONIC, &cur);
- 	       /* Timeout after 1s */
- 	       if (cur.tv_sec > timeout.tv_sec + 1 ||
-@@ -1964,6 +1990,7 @@
- 		       ret = -1;
- 		       break;
- 	       }
-+#endif
-        }
-     } while (ret && errno == EINTR);
- 
diff --git a/nixpkgs/pkgs/development/libraries/libgda/default.nix b/nixpkgs/pkgs/development/libraries/libgda/default.nix
index 95860ac94201..bb6402dc4287 100644
--- a/nixpkgs/pkgs/development/libraries/libgda/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libgda/default.nix
@@ -9,11 +9,11 @@ assert postgresSupport -> postgresql != null;
 
 (if stdenv.isAarch64 then overrideCC stdenv gcc6 else stdenv).mkDerivation rec {
   pname = "libgda";
-  version = "5.2.8";
+  version = "5.2.9";
 
   src = fetchurl {
     url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
-    sha256 = "0id4my5wh2m6rd7ijqp2azsjdb4l4yjrv3imq71kly00gjc6v1z2";
+    sha256 = "16vxv2qvysh22s8h9h6irx96sacagxkz0i4qgi1wc6ibly6fvjjr";
   };
   configureFlags = with stdenv.lib; [ "--enable-gi-system-install=no" ]
     ++ (optional (mysqlSupport) "--with-mysql=yes")
diff --git a/nixpkgs/pkgs/development/libraries/libimobiledevice/disable_sslv3.patch b/nixpkgs/pkgs/development/libraries/libimobiledevice/disable_sslv3.patch
deleted file mode 100644
index 646b829496fa..000000000000
--- a/nixpkgs/pkgs/development/libraries/libimobiledevice/disable_sslv3.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From e19de4f0d4cb70e30017edfc6b4ca1b89ffbd381 Mon Sep 17 00:00:00 2001
-From: Franz Pletz <fpletz@fnordicwalking.de>
-Date: Thu, 14 Jan 2016 14:58:23 +0100
-Subject: [PATCH] Disable SSLv3
-
----
- src/idevice.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/idevice.c b/src/idevice.c
-index ce27495..8f03094 100644
---- a/src/idevice.c
-+++ b/src/idevice.c
-@@ -678,7 +678,7 @@ LIBIMOBILEDEVICE_API idevice_error_t idevice_connection_enable_ssl(idevice_conne
- 	}
- 	BIO_set_fd(ssl_bio, (int)(long)connection->data, BIO_NOCLOSE);
- 
--	SSL_CTX *ssl_ctx = SSL_CTX_new(SSLv3_method());
-+	SSL_CTX *ssl_ctx = SSL_CTX_new(SSLv23_method());
- 	if (ssl_ctx == NULL) {
- 		debug_info("ERROR: Could not create SSL context.");
- 		BIO_free(ssl_bio);
--- 
-2.7.0
-
diff --git a/nixpkgs/pkgs/development/libraries/libnsl/cdefs.patch b/nixpkgs/pkgs/development/libraries/libnsl/cdefs.patch
deleted file mode 100644
index dbbe800a3479..000000000000
--- a/nixpkgs/pkgs/development/libraries/libnsl/cdefs.patch
+++ /dev/null
@@ -1,30 +0,0 @@
---- a/src/rpcsvc/nislib.h
-+++ b/src/rpcsvc/nislib.h
-@@ -19,6 +19,7 @@
- #ifndef	__RPCSVC_NISLIB_H__
- #define	__RPCSVC_NISLIB_H__
- 
-+#include <sys/cdefs.h>
- #include <features.h>
- 
- __BEGIN_DECLS
---- a/src/rpcsvc/ypclnt.h
-+++ b/src/rpcsvc/ypclnt.h
-@@ -20,6 +20,7 @@
- #ifndef	__RPCSVC_YPCLNT_H__
- #define	__RPCSVC_YPCLNT_H__
- 
-+#include <sys/cdefs.h>
- #include <features.h>
- 
- /* Some defines */
---- a/src/rpcsvc/ypupd.h
-+++ b/src/rpcsvc/ypupd.h
-@@ -33,6 +33,7 @@
- #ifndef __RPCSVC_YPUPD_H__
- #define __RPCSVC_YPUPD_H__
- 
-+#include <sys/cdefs.h>
- #include <features.h>
- 
- #include <rpc/rpc.h>
diff --git a/nixpkgs/pkgs/development/libraries/libnsl/default.nix b/nixpkgs/pkgs/development/libraries/libnsl/default.nix
index 9e8a46b2e6b3..790064847432 100644
--- a/nixpkgs/pkgs/development/libraries/libnsl/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libnsl/default.nix
@@ -1,21 +1,19 @@
 { stdenv, fetchFromGitHub, autoreconfHook, libtirpc, pkgconfig }:
 
 stdenv.mkDerivation rec {
-  name = "libnsl-${version}";
-  version = "1.1.0";
+  pname = "libnsl";
+  version = "1.2.0";
 
   src = fetchFromGitHub {
     owner = "thkukuk";
-    repo = "libnsl";
-    rev = "libnsl-${version}";
-    sha256 = "0h8br0gmgw3fp5fmy6bfbj1qlk9hry1ssg25ssjgxbd8spczpscs";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "1chzqhcgh0yia9js8mh92cmhyka7rh32ql6b3mgdk26n94dqzs8b";
   };
 
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ libtirpc ];
 
-  patches = stdenv.lib.optionals stdenv.hostPlatform.isMusl [ ./cdefs.patch ./nis_h.patch ];
-
   meta = with stdenv.lib; {
     description = "Client interface library for NIS(YP) and NIS+";
     homepage = https://github.com/thkukuk/libnsl;
diff --git a/nixpkgs/pkgs/development/libraries/libnsl/nis_h.patch b/nixpkgs/pkgs/development/libraries/libnsl/nis_h.patch
deleted file mode 100644
index 199259df2e8d..000000000000
--- a/nixpkgs/pkgs/development/libraries/libnsl/nis_h.patch
+++ /dev/null
@@ -1,45 +0,0 @@
---- a/src/rpcsvc/nis.h
-+++ b/src/rpcsvc/nis.h
-@@ -32,6 +32,7 @@
- #ifndef _RPCSVC_NIS_H
- #define _RPCSVC_NIS_H 1
- 
-+#include <sys/cdefs.h>
- #include <features.h>
- #include <rpc/rpc.h>
- #include <rpcsvc/nis_tags.h>
-@@ -56,6 +57,34 @@
-  *                                              <kukuk@suse.de>
-  */
- 
-+#ifndef rawmemchr
-+#define rawmemchr(s,c) memchr((s),(size_t)-1,(c))
-+#endif
-+
-+#ifndef __asprintf
-+#define __asprintf asprintf
-+#endif
-+
-+#ifndef __mempcpy
-+#define __mempcpy mempcpy
-+#endif
-+
-+#ifndef __strtok_r
-+#define __strtok_r strtok_r
-+#endif
-+
-+#ifndef __always_inline
-+#define __always_inline __attribute__((__always_inline__))
-+#endif
-+
-+#ifndef TEMP_FAILURE_RETRY
-+#define TEMP_FAILURE_RETRY(exp) ({ \
-+typeof (exp) _rc; \
-+ do { \
-+  _rc = (exp); \
-+ } while (_rc == -1 && errno == EINTR); \
-+ _rc; })
-+#endif
- 
- #ifndef __nis_object_h
- #define __nis_object_h
diff --git a/nixpkgs/pkgs/development/libraries/libosinfo/default.nix b/nixpkgs/pkgs/development/libraries/libosinfo/default.nix
index e947ec22bf84..9efeb0f678e0 100644
--- a/nixpkgs/pkgs/development/libraries/libosinfo/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libosinfo/default.nix
@@ -3,11 +3,12 @@
 }:
 
 stdenv.mkDerivation rec {
-  name = "libosinfo-1.4.0";
+  pname = "libosinfo";
+  version = "1.5.0";
 
   src = fetchurl {
-    url = "https://releases.pagure.org/libosinfo/${name}.tar.gz";
-    sha256 = "0ra1p2rnnwkq0181ayn0l0rs1pvk4a0i8fa08nqjfmqs5fl637m2";
+    url = "https://releases.pagure.org/${pname}/${pname}-${version}.tar.gz";
+    sha256 = "12b0xj9fz9q91d1pz9xm6aqap5k1ip0m9m3qvqmwjy1lk1kjasdz";
   };
 
   outputs = [ "out" "dev" "devdoc" ];
diff --git a/nixpkgs/pkgs/development/libraries/libpointmatcher/default.nix b/nixpkgs/pkgs/development/libraries/libpointmatcher/default.nix
index 2b8fc1fcc8f7..cd841a9d8f84 100644
--- a/nixpkgs/pkgs/development/libraries/libpointmatcher/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libpointmatcher/default.nix
@@ -1,17 +1,18 @@
-{stdenv, fetchFromGitHub, cmake, eigen, boost, libnabo}:
+{ stdenv, fetchFromGitHub, cmake, eigen, boost, libnabo }:
 
 stdenv.mkDerivation rec {
-  version = "2016-09-11";
-  name = "libpointmatcher-${version}";
+  pname = "libpointmatcher";
+  version = "1.3.1";
 
   src = fetchFromGitHub {
     owner = "ethz-asl";
-    repo = "libpointmatcher";
-    rev = "75044815d40ff934fe0bb7e05ed8bbf18c06493b";
-    sha256 = "1s7ilvg3lhr1fq8sxw05ydmbd3kl46496jnyxprhnpgvpmvqsbzl";
+    repo = pname;
+    rev = version;
+    sha256 = "0lai6sr3a9dj1j4pgjjyp7mx10wixy5wpvbka8nsc2danj6xhdyd";
   };
 
-  buildInputs = [cmake eigen boost libnabo];
+  nativeBuildInputs = [ cmake ];
+  buildInputs = [ eigen boost libnabo ];
 
   enableParallelBuilding = true;
 
@@ -19,11 +20,11 @@ stdenv.mkDerivation rec {
     -DEIGEN_INCLUDE_DIR=${eigen}/include/eigen3
   ";
 
+  doCheck = true;
   checkPhase = ''
-  export LD_LIBRARY_PATH=$PWD
-  ./utest/utest --path ../examples/data/
+    export LD_LIBRARY_PATH=$PWD
+    ./utest/utest --path ../examples/data/
   '';
-  doCheck = true;
 
   meta = with stdenv.lib; {
     inherit (src.meta) homepage;
diff --git a/nixpkgs/pkgs/development/libraries/libproxy/default.nix b/nixpkgs/pkgs/development/libraries/libproxy/default.nix
index 0e0499251eb9..3b050c3dc6a0 100644
--- a/nixpkgs/pkgs/development/libraries/libproxy/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, cmake, zlib
+{ stdenv, fetchFromGitHub, pkgconfig, cmake, zlib, fetchpatch
 , dbus, networkmanager, spidermonkey_38, pcre, python2, python3
 , SystemConfiguration, CoreFoundation, JavaScriptCore }:
 
@@ -30,6 +30,12 @@ stdenv.mkDerivation rec {
     )
   '';
 
+  patches = stdenv.lib.optional stdenv.isDarwin
+    (fetchpatch {
+      url = "https://github.com/libproxy/libproxy/commit/44158f03f8522116758d335688ed840dfcb50ac8.patch";
+      sha256 = "0axfvb6j7gcys6fkwi9dkn006imhvm3kqr83gpwban8419n0q5v1";
+    });
+
   doCheck = false; # fails 1 out of 10 tests
 
   meta = with stdenv.lib; {
diff --git a/nixpkgs/pkgs/development/libraries/libressl/default.nix b/nixpkgs/pkgs/development/libraries/libressl/default.nix
index 11ed2eb0044a..e694c353df09 100644
--- a/nixpkgs/pkgs/development/libraries/libressl/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libressl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, lib }:
+{ stdenv, fetchurl, lib, cmake }:
 
 let
 
@@ -11,7 +11,17 @@ let
       inherit sha256;
     };
 
-    configureFlags = [ "--enable-nc" ];
+    nativeBuildInputs = [ cmake ];
+
+    cmakeFlags = [ "-DENABLE_NC=ON" "-DBUILD_SHARED_LIBS=ON" ];
+
+    # The autoconf build is broken as of 2.9.1, resulting in the following error:
+    # libressl-2.9.1/tls/.libs/libtls.a', needed by 'handshake_table'.
+    # Fortunately LibreSSL provides a CMake build as well, so opt for CMake by
+    # removing ./configure pre-config.
+    preConfigure = ''
+      rm configure
+    '';
 
     enableParallelBuilding = true;
 
@@ -19,6 +29,8 @@ let
 
     postFixup = ''
       moveToOutput "bin/nc" "$nc"
+      moveToOutput "bin/openssl" "$bin"
+      moveToOutput "bin/ocspcheck" "$bin"
       moveToOutput "share/man/man1/nc.1${lib.optionalString (dontGzipMan==null) ".gz"}" "$nc"
     '';
 
@@ -46,7 +58,7 @@ in {
   };
 
   libressl_2_9 = generic {
-    version = "2.9.0";
-    sha256 = "1x1wl6b449m6hfhyxxzxbf2v8yfb5q92q6d01hdg28xp1222jpzb";
+    version = "2.9.1";
+    sha256 = "1y32iz64rqh74m1g641b39h3293dqi4la7i0ckai1p4lcs2xvr1r";
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/libseccomp/default.nix b/nixpkgs/pkgs/development/libraries/libseccomp/default.nix
index 54ca09a7b0db..6b38bcf2c778 100644
--- a/nixpkgs/pkgs/development/libraries/libseccomp/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libseccomp/default.nix
@@ -28,7 +28,11 @@ stdenv.mkDerivation rec {
     homepage    = "https://github.com/seccomp/libseccomp";
     license     = licenses.lgpl21;
     platforms   = platforms.linux;
-    badPlatforms = platforms.riscv;
+    badPlatforms = [
+      "alpha-linux"
+      "riscv64-linux" "riscv32-linux"
+      "sparc-linux" "sparc64-linux"
+    ];
     maintainers = with maintainers; [ thoughtpolice ];
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/libsnark/darwin-fix-clock-gettime.patch b/nixpkgs/pkgs/development/libraries/libsnark/darwin-fix-clock-gettime.patch
deleted file mode 100644
index 2eee84d1c4b8..000000000000
--- a/nixpkgs/pkgs/development/libraries/libsnark/darwin-fix-clock-gettime.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-Adapted from https://github.com/zcash/libsnark/pull/10
-
-diff --git a/depends/libff/libff/common/profiling.cpp b/depends/libff/libff/common/profiling.cpp
-index f2a1985..319149c 100755
---- a/depends/libff/libff/common/profiling.cpp
-+++ b/depends/libff/libff/common/profiling.cpp
-@@ -27,6 +27,13 @@
- #include <proc/readproc.h>
- #endif
- 
-+#ifdef __MACH__
-+#include <time.h>
-+#include <sys/time.h>
-+#include <mach/clock.h>
-+#include <mach/mach.h>
-+#endif
-+
- namespace libff {
- 
- long long get_nsec_time()
-@@ -42,10 +49,20 @@ long long get_nsec_cpu_time()
- 	return 0;
- #else
-     ::timespec ts;
-+#ifdef __MACH__
-+    clock_serv_t cclock;
-+    mach_timespec_t mts;
-+    host_get_clock_service(mach_host_self(), CALENDAR_CLOCK, &cclock);
-+    clock_get_time(cclock, &mts);
-+    mach_port_deallocate(mach_task_self(), cclock);
-+    ts.tv_sec = mts.tv_sec;
-+    ts.tv_nsec = mts.tv_nsec;
-+#else
-     if ( ::clock_gettime(CLOCK_PROCESS_CPUTIME_ID, &ts) )
-         throw ::std::runtime_error("clock_gettime(CLOCK_PROCESS_CPUTIME_ID) failed");
-         // If we expected this to work, don't silently ignore failures, because that would hide the problem and incur an unnecessarily system-call overhead. So if we ever observe this exception, we should probably add a suitable #ifdef .
-         //TODO: clock_gettime(CLOCK_PROCESS_CPUTIME_ID) is not supported by native Windows. What about Cygwin? Should we #ifdef on CLOCK_PROCESS_CPUTIME_ID or on __linux__?
-+#endif
-     return ts.tv_sec * 1000000000ll + ts.tv_nsec;
- #endif
- }
diff --git a/nixpkgs/pkgs/development/libraries/libsnark/default.nix b/nixpkgs/pkgs/development/libraries/libsnark/default.nix
index 4ea2209160f8..15d8169f1024 100644
--- a/nixpkgs/pkgs/development/libraries/libsnark/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libsnark/default.nix
@@ -19,8 +19,6 @@ in stdenv.mkDerivation rec {
     fetchSubmodules = true;
   };
 
-  patches = [ ./darwin-fix-clock-gettime.patch ];
-
   enableParallelBuilding = true;
 
   meta = with stdenv.lib; {
diff --git a/nixpkgs/pkgs/development/libraries/libsoup/default.nix b/nixpkgs/pkgs/development/libraries/libsoup/default.nix
index d0023a3d4f36..61cad10c190c 100644
--- a/nixpkgs/pkgs/development/libraries/libsoup/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libsoup/default.nix
@@ -5,11 +5,11 @@
 stdenv.mkDerivation rec {
   name = "${pname}-${version}";
   pname = "libsoup";
-  version = "2.66.0";
+  version = "2.66.1";
 
   src = fetchurl {
     url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${name}.tar.xz";
-    sha256 = "08c9kkdhzy504gv23pfdm4sq3dd3j20sikwz6gv0qrwcdjnw5bai";
+    sha256 = "1zs3bhspwg7fggxd7x1rrggpkcf2j9ch6dhncq9syh252z0vcb2a";
   };
 
   postPatch = ''
diff --git a/nixpkgs/pkgs/development/libraries/libtins/default.nix b/nixpkgs/pkgs/development/libraries/libtins/default.nix
index 1af7548ac962..483fb56f43b2 100644
--- a/nixpkgs/pkgs/development/libraries/libtins/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libtins/default.nix
@@ -31,7 +31,11 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
   doCheck = true;
-  checkPhase = "make tests && LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PWD/lib make test";
+  preCheck = ''
+    export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PWD/lib
+    export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:$PWD/lib
+  '';
+  checkTarget = "tests test";
 
   meta = with stdenv.lib; {
     description = "High-level, multiplatform C++ network packet sniffing and crafting library";
diff --git a/nixpkgs/pkgs/development/libraries/libuv/default.nix b/nixpkgs/pkgs/development/libraries/libuv/default.nix
index 32697bdc0e01..4fdfc8556425 100644
--- a/nixpkgs/pkgs/development/libraries/libuv/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libuv/default.nix
@@ -1,14 +1,14 @@
 { stdenv, lib, fetchpatch, fetchFromGitHub, autoconf, automake, libtool, pkgconfig, ApplicationServices, CoreServices }:
 
 stdenv.mkDerivation rec {
-  version = "1.27.0";
+  version = "1.28.0";
   pname = "libuv";
 
   src = fetchFromGitHub {
     owner = pname;
     repo = pname;
     rev = "v${version}";
-    sha256 = "1nhd3772qymlv0b251wg9rrqz279vki4hnd4s23yyll0kpmzkpac";
+    sha256 = "0l0gx69sdy3sv3pirjbca2ws54n9d83mj0j96h77k0ncywimvi64";
   };
 
   postPatch = let
diff --git a/nixpkgs/pkgs/development/libraries/libva/default.nix b/nixpkgs/pkgs/development/libraries/libva/default.nix
index 7f17b9af08b3..752d56a344e4 100644
--- a/nixpkgs/pkgs/development/libraries/libva/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libva/default.nix
@@ -6,14 +6,14 @@
 
 stdenv.mkDerivation rec {
   name = "libva-${lib.optionalString minimal "minimal-"}${version}";
-  version = "2.4.0";
+  version = "2.4.1";
 
   # update libva-utils and vaapiIntel as well
   src = fetchFromGitHub {
     owner  = "01org";
     repo   = "libva";
     rev    = version;
-    sha256 = "1b58n6rjfsfjfw1s5kdfa0jpfiqs83g2w14s7sfp1qkckkz3988l";
+    sha256 = "06kqff05jhd87yi53gyc2qivgg4sbf19qyznm9s4dyz92k04cl5c";
   };
 
   outputs = [ "dev" "out" ];
diff --git a/nixpkgs/pkgs/development/libraries/libxmlb/default.nix b/nixpkgs/pkgs/development/libraries/libxmlb/default.nix
index 257ac8e277dc..c5ff7c11713b 100644
--- a/nixpkgs/pkgs/development/libraries/libxmlb/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libxmlb/default.nix
@@ -2,7 +2,7 @@
 
 stdenv.mkDerivation rec {
   name = "libxmlb-${version}";
-  version = "0.1.8";
+  version = "0.1.9";
 
   outputs = [ "out" "lib" "dev" "devdoc" ];
 
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
     owner = "hughsie";
     repo = "libxmlb";
     rev = version;
-    sha256 = "0nry2a4vskfklykd20smp4maqpzibc65rzyv4i71nrc55dyjpy7x";
+    sha256 = "1rdpsssrwpx24snqb82hisjybnpz9fq91wbmxfi2s63xllzi14b6";
   };
 
   nativeBuildInputs = [ meson ninja python3 pkgconfig gobject-introspection gtk-doc shared-mime-info docbook_xsl docbook_xml_dtd_43 ];
@@ -33,6 +33,6 @@ stdenv.mkDerivation rec {
     homepage = https://github.com/hughsie/libxmlb;
     license = licenses.lgpl21Plus;
     maintainers = with maintainers; [ jtojnar ];
-    platforms = platforms.unix;
+    platforms = platforms.linux;
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/libxslt/default.nix b/nixpkgs/pkgs/development/libraries/libxslt/default.nix
index ce79b2ac5ff9..41633d91f3bd 100644
--- a/nixpkgs/pkgs/development/libraries/libxslt/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libxslt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libxml2, findXMLCatalogs, python2, libgcrypt
+{ stdenv, fetchurl, fetchpatch, libxml2, findXMLCatalogs, python2, libgcrypt
 , cryptoSupport ? false
 , pythonSupport ? stdenv.buildPlatform == stdenv.hostPlatform
 }:
@@ -18,6 +18,14 @@ stdenv.mkDerivation rec {
     sha256 = "1j1q1swnsy8jgi9x7mclvkrqhfgn09886gdlr9wzk7a08i8n0dlf";
   };
 
+  patches = [
+    (fetchpatch {
+      name = "CVE-2019-11068.patch";
+      url = "https://gitlab.gnome.org/GNOME/libxslt/commit/e03553605b45c88f0b4b2980adfbbb8f6fca2fd6.patch";
+      sha256 = "0pkpb4837km15zgg6h57bncp66d5lwrlvkr73h0lanywq7zrwhj8";
+    })
+  ];
+
   outputs = [ "bin" "dev" "out" "man" "doc" ] ++ stdenv.lib.optional pythonSupport "py";
 
   buildInputs = [ libxml2.dev ]
diff --git a/nixpkgs/pkgs/development/libraries/linbox/default.nix b/nixpkgs/pkgs/development/libraries/linbox/default.nix
index ef2dbb10fba1..cde422906dac 100644
--- a/nixpkgs/pkgs/development/libraries/linbox/default.nix
+++ b/nixpkgs/pkgs/development/libraries/linbox/default.nix
@@ -12,13 +12,13 @@
 stdenv.mkDerivation rec {
   name = "${pname}-${version}";
   pname = "linbox";
-  version = "1.5.2";
+  version = "1.6.1";
 
   src = fetchFromGitHub {
     owner = "linbox-team";
     repo = "${pname}";
     rev = "v${version}";
-    sha256 = "1wfivlwp30mzdy1697w7rzb8caajim50mc8h27k82yipn2qc5n4i";
+    sha256 = "11mgj7pkppvzmhx5g6wfnzisk36z00gqzzq9p14hzh5dbdhk3693";
   };
 
   nativeBuildInputs = [
@@ -51,16 +51,6 @@ stdenv.mkDerivation rec {
     "--enable-sage"
   ];
 
-  patches = stdenv.lib.optionals withSage [
-    # https://trac.sagemath.org/ticket/24214#comment:39
-    # Will be resolved by
-    # https://github.com/linbox-team/linbox/issues/69
-    (fetchpatch {
-      url = "https://raw.githubusercontent.com/sagemath/sage/a843f48b7a4267e44895a3dfa892c89c85b85611/build/pkgs/linbox/patches/linbox_charpoly_fullCRA.patch";
-      sha256 = "16nxfzfknra3k2yk3xy0k8cq9rmnmsch3dnkb03kx15h0y0jmibk";
-    })
-  ];
-
   doCheck = true;
 
   enableParallelBuilding = true;
@@ -71,6 +61,7 @@ stdenv.mkDerivation rec {
     license = stdenv.lib.licenses.lgpl21Plus;
     maintainers = [stdenv.lib.maintainers.timokau];
     platforms = stdenv.lib.platforms.unix;
+    broken = stdenv.isDarwin || stdenv.isAarch64; # https://trac.sagemath.org/ticket/26932#comment:21
     homepage = http://linalg.org/;
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/mesa/darwin-clock-gettime.patch b/nixpkgs/pkgs/development/libraries/mesa/darwin-clock-gettime.patch
deleted file mode 100644
index 94e90a1c5871..000000000000
--- a/nixpkgs/pkgs/development/libraries/mesa/darwin-clock-gettime.patch
+++ /dev/null
@@ -1,76 +0,0 @@
-diff --git a/include/c11/threads_posix.h b/include/c11/threads_posix.h
-index 45cb6075e6..62937311b9 100644
---- a/include/c11/threads_posix.h
-+++ b/include/c11/threads_posix.h
-@@ -36,6 +36,11 @@
- #include <sched.h>
- #include <stdint.h> /* for intptr_t */
- 
-+#ifdef __MACH__
-+#include <mach/clock.h>
-+#include <mach/mach.h>
-+#endif
-+
- /*
- Configuration macro:
- 
-@@ -383,12 +388,25 @@ tss_set(tss_t key, void *val)
- /*-------------------- 7.25.7 Time functions --------------------*/
- // 7.25.6.1
- #ifndef HAVE_TIMESPEC_GET
-+
- static inline int
- timespec_get(struct timespec *ts, int base)
- {
-     if (!ts) return 0;
-     if (base == TIME_UTC) {
-+#ifdef __MACH__
-+        if (ts != NULL) {
-+            clock_serv_t cclock;
-+            mach_timespec_t mts;
-+            host_get_clock_service(mach_host_self(), CALENDAR_CLOCK, &cclock);
-+            clock_get_time(cclock, &mts);
-+            mach_port_deallocate(mach_task_self(), cclock);
-+            ts->tv_sec = mts.tv_sec;
-+            ts->tv_nsec = mts.tv_nsec;
-+        }
-+#else
-         clock_gettime(CLOCK_REALTIME, ts);
-+#endif
-         return base;
-     }
-     return 0;
-diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c
-index 1208ebb315..e1378fb1f0 100644
---- a/src/egl/drivers/dri2/egl_dri2.c
-+++ b/src/egl/drivers/dri2/egl_dri2.c
-@@ -65,6 +65,11 @@
- #include "util/u_vector.h"
- #include "mapi/glapi/glapi.h"
- 
-+#ifdef __MACH__
-+#include <mach/clock.h>
-+#include <mach/mach.h>
-+#endif
-+
- #define NUM_ATTRIBS 12
- 
- static void
-@@ -3092,7 +3097,17 @@ dri2_client_wait_sync(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync,
- 
-             /* We override the clock to monotonic when creating the condition
-              * variable. */
-+#ifdef __MACH__
-+            clock_serv_t cclock;
-+            mach_timespec_t mts;
-+            host_get_clock_service(mach_host_self(), CALENDAR_CLOCK, &cclock);
-+            clock_get_time(cclock, &mts);
-+            mach_port_deallocate(mach_task_self(), cclock);
-+            current.tv_sec = mts.tv_sec;
-+            current.tv_nsec = mts.tv_nsec;
-+#else
-             clock_gettime(CLOCK_MONOTONIC, &current);
-+#endif
- 
-             /* calculating when to expire */
-             expire.tv_nsec = timeout % 1000000000L;
diff --git a/nixpkgs/pkgs/development/libraries/mesa/default.nix b/nixpkgs/pkgs/development/libraries/mesa/default.nix
index a8a29414be4d..77ea6783b775 100644
--- a/nixpkgs/pkgs/development/libraries/mesa/default.nix
+++ b/nixpkgs/pkgs/development/libraries/mesa/default.nix
@@ -131,7 +131,7 @@ let
           url = https://cgit.freedesktop.org/mesa/mesa/patch/?id=bcc4bfc8e80da5dc4c6ee44f791f2112dac208d1;
           sha256 = "0rijkx80anbb7g14cg9g11ha7lcf7sixc7xsjam6myyd68nl3n5n";
         })
-      ] ++ optional stdenv.isDarwin ./darwin-clock-gettime.patch;
+      ];
 
       outputs = [ "out" "dev" "drivers" ]
                 ++ optional (elem "swrast" galliumDrivers) "osmesa";
diff --git a/nixpkgs/pkgs/development/libraries/nv-codec-headers/default.nix b/nixpkgs/pkgs/development/libraries/nv-codec-headers/default.nix
index 07ec502cd12a..73ed932afb63 100644
--- a/nixpkgs/pkgs/development/libraries/nv-codec-headers/default.nix
+++ b/nixpkgs/pkgs/development/libraries/nv-codec-headers/default.nix
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   meta = {
     description = "FFmpeg version of headers for NVENC";
     homepage = http://ffmpeg.org/;
-    license = stdenv.lib.licenses.gpl3Plus;
+    license = stdenv.lib.licenses.mit;
     maintainers = [ stdenv.lib.maintainers.MP2E ];
     platforms = stdenv.lib.platforms.all;
   };
diff --git a/nixpkgs/pkgs/development/libraries/oniguruma/default.nix b/nixpkgs/pkgs/development/libraries/oniguruma/default.nix
index 4c994d596ba1..b54f34fbb2c3 100644
--- a/nixpkgs/pkgs/development/libraries/oniguruma/default.nix
+++ b/nixpkgs/pkgs/development/libraries/oniguruma/default.nix
@@ -2,13 +2,13 @@
 
 stdenv.mkDerivation rec {
   name = "onig-${version}";
-  version = "6.9.1";
+  version = "6.9.2";
 
   src = fetchFromGitHub {
     owner = "kkos";
     repo = "oniguruma";
     rev = "v${version}";
-    sha256 = "0dbdd9r15fsqn0rimkjwlv8v68v4i1830h0m7dw56b335wwl6bbg";
+    sha256 = "15asc9v6ylal8fwzlnrh673mp62wngxvv9jx7h86vhljjdap6yfc";
   };
 
   nativeBuildInputs = [ cmake ];
diff --git a/nixpkgs/pkgs/development/libraries/opencsg/default.nix b/nixpkgs/pkgs/development/libraries/opencsg/default.nix
index e0a6c6a5705e..11c66f0d497b 100644
--- a/nixpkgs/pkgs/development/libraries/opencsg/default.nix
+++ b/nixpkgs/pkgs/development/libraries/opencsg/default.nix
@@ -1,5 +1,5 @@
 {stdenv, fetchurl, libGLU_combined, freeglut, glew, libXmu, libXext, libX11
-  }:
+, qmake, GLUT, fixDarwinDylibNames }:
 
 stdenv.mkDerivation rec {
   version = "1.4.2";
@@ -9,27 +9,42 @@ stdenv.mkDerivation rec {
     sha256 = "1ysazynm759gnw1rdhn9xw9nixnzrlzrc462340a6iif79fyqlnr";
   };
 
-  buildInputs = [libGLU_combined freeglut glew libXmu libXext libX11];
+  nativeBuildInputs = [ qmake ]
+    ++ stdenv.lib.optional stdenv.isDarwin fixDarwinDylibNames;
+
+  buildInputs = [ glew ]
+    ++ stdenv.lib.optionals stdenv.isLinux [ libGLU_combined freeglut libXmu libXext libX11 ]
+    ++ stdenv.lib.optional stdenv.isDarwin GLUT;
 
   doCheck = false;
 
+  patches = [ ./fix-pro-files.patch ];
+
   preConfigure = ''
-    sed -i 's/^\(LIBS *=.*\)$/\1 -lX11/' example/Makefile
+    rm example/Makefile src/Makefile
+    qmakeFlags="$qmakeFlags INSTALLDIR=$out"
   '';
 
-  installPhase = ''
-    mkdir -pv "$out/"{bin,share/doc/opencsg}
-
-    cp example/opencsgexample "$out/bin"
-    cp -r include lib "$out"
+  postInstall = ''
+    install -D license.txt "$out/share/doc/opencsg/license.txt"
+  '' + stdenv.lib.optionalString stdenv.isDarwin ''
+    mkdir -p $out/Applications
+    mv $out/bin/*.app $out/Applications
+    rmdir $out/bin || true
+  '';
 
-    cp license.txt "$out/share/doc/opencsg"
+  postFixup = stdenv.lib.optionalString stdenv.isDarwin ''
+    app=$out/Applications/opencsgexample.app/Contents/MacOS/opencsgexample
+    install_name_tool -change \
+      $(otool -L $app | awk '/opencsg.+dylib/ { print $1 }') \
+      $(otool -D $out/lib/libopencsg.dylib | tail -n 1) \
+      $app
   '';
 
   meta = with stdenv.lib; {
     description = "Constructive Solid Geometry library";
     homepage = http://www.opencsg.org/;
-    platforms = platforms.linux;
+    platforms = platforms.unix;
     maintainers = [ maintainers.raskin ];
     license = licenses.gpl2;
   };
diff --git a/nixpkgs/pkgs/development/libraries/opencsg/fix-pro-files.patch b/nixpkgs/pkgs/development/libraries/opencsg/fix-pro-files.patch
new file mode 100644
index 000000000000..462b44c8f40c
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/opencsg/fix-pro-files.patch
@@ -0,0 +1,21 @@
+diff -ur OpenCSG-1.4.2-pristine/example/example.pro OpenCSG-1.4.2/example/example.pro
+--- OpenCSG-1.4.2-pristine/example/example.pro	2016-09-27 06:11:16.000000000 +0900
++++ OpenCSG-1.4.2/example/example.pro	2019-05-07 10:45:18.785251737 +0900
+@@ -6,7 +6,9 @@
+ INCLUDEPATH += ../include
+ LIBS += -L../lib -lopencsg -lGLEW
+ 
+-INSTALLDIR = /usr/local
++isEmpty(INSTALLDIR) {
++  INSTALLDIR = /usr/local
++}
+ INSTALLS += target
+ target.path = $$INSTALLDIR/bin
+ 
+diff -ur OpenCSG-1.4.2-pristine/opencsg.pro OpenCSG-1.4.2/opencsg.pro
+--- OpenCSG-1.4.2-pristine/opencsg.pro	2016-09-27 06:11:16.000000000 +0900
++++ OpenCSG-1.4.2/opencsg.pro	2019-05-07 10:44:50.578698165 +0900
+@@ -1,2 +1,3 @@
+ TEMPLATE = subdirs
+ SUBDIRS  = src example
++CONFIG   += ordered
diff --git a/nixpkgs/pkgs/development/libraries/openexr/default.nix b/nixpkgs/pkgs/development/libraries/openexr/default.nix
index b575fa0ef08c..54b617fdc014 100644
--- a/nixpkgs/pkgs/development/libraries/openexr/default.nix
+++ b/nixpkgs/pkgs/development/libraries/openexr/default.nix
@@ -1,4 +1,9 @@
-{ lib, stdenv, fetchurl, autoconf, automake, libtool, pkgconfig, zlib, ilmbase }:
+{ lib, stdenv, buildPackages, fetchurl, autoconf, automake, libtool, pkgconfig, zlib, ilmbase, }:
+
+let
+  # Doesn't really do anything when not crosscompiling
+  emulator = stdenv.hostPlatform.emulator buildPackages;
+in
 
 stdenv.mkDerivation rec {
   name = "openexr-${version}";
@@ -15,13 +20,28 @@ stdenv.mkDerivation rec {
 
   outputs = [ "bin" "dev" "out" "doc" ];
 
+  # Needed because there are some generated sources. Solution: just run them under QEMU.
+  postPatch = ''
+    for file in b44ExpLogTable dwaLookups
+    do
+      # Ecape for both sh and Automake
+      emu=${lib.escapeShellArg (lib.replaceStrings ["$"] ["$$"] emulator)}
+      before="./$file > $file.h"
+      after="$emu $before"
+      substituteInPlace IlmImf/Makefile.am \
+        --replace "$before" "$after"
+    done
+
+    # Make sure the patch succeeded
+    [[ $(grep "$emu" IlmImf/Makefile.am | wc -l) = 2 ]]
+  '';
+
   preConfigure = ''
     patchShebangs ./bootstrap
     ./bootstrap
   '';
 
-  nativeBuildInputs = [ pkgconfig ];
-  buildInputs = [ autoconf automake libtool ];
+  nativeBuildInputs = [ pkgconfig autoconf automake libtool ];
   propagatedBuildInputs = [ ilmbase zlib ];
 
   enableParallelBuilding = true;
diff --git a/nixpkgs/pkgs/development/libraries/physics/rivet/key_val.patch b/nixpkgs/pkgs/development/libraries/physics/rivet/key_val.patch
deleted file mode 100644
index 0b24d703dac8..000000000000
--- a/nixpkgs/pkgs/development/libraries/physics/rivet/key_val.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff --git a/bin/rivet-cmphistos b/bin/rivet-cmphistos
---- a/bin/rivet-cmphistos
-+++ b/bin/rivet-cmphistos
-@@ -371,7 +371,7 @@ if __name__ == '__main__':
-         #     plot[key] = val
-         if plotoptions.has_key("PLOT"):
-             for key_val in plotoptions["PLOT"]:
--                key, val = [s.strip() for s in key_val.split("=")]
-+                key, val = [s.strip() for s in key_val.split("=", 1)]
-                 plot[key] = val
-         if opts.LINEAR:
-             plot['LogY'] = '0'
diff --git a/nixpkgs/pkgs/development/libraries/physics/rivet/zaxis_fix.patch b/nixpkgs/pkgs/development/libraries/physics/rivet/zaxis_fix.patch
deleted file mode 100644
index c255db565e6c..000000000000
--- a/nixpkgs/pkgs/development/libraries/physics/rivet/zaxis_fix.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-diff --git a/bin/make-plots b/bin/make-plots
-index abb024d..f59293d 100755
---- a/bin/make-plots
-+++ b/bin/make-plots
-@@ -1152,8 +1152,8 @@ class ColorScale(Described):
- 
-         zcustommajortickmarks = int(self.description.get('ZMajorTickMarks', -1))
-         zcustomminortickmarks = int(self.description.get('ZMinorTickMarks', -1))
--        zcustommajorticks=[]
--        zcustomminorticks=[]
-+        zcustommajorticks=None
-+        zcustomminorticks=None
-         if self.description.has_key('ZCustomMajorTicks') and self.description['ZCustomMajorTicks']!='':
-             # TODO: Would be nice to have less invisible separation of the custom ticks than split on tabs
-             ticks = self.description['ZCustomMajorTicks'].strip().split('\t')
-@@ -2214,7 +2214,7 @@ class Ticks(object):
- 
- class XTicks(Ticks):
- 
--    def draw(self, custommajorticks=[], customminorticks=[], custommajortickmarks=-1, customminortickmarks=-1,drawlabels=True):
-+    def draw(self, custommajorticks=None, customminorticks=None, custommajortickmarks=-1, customminortickmarks=-1,drawlabels=True):
-         twosided = bool(int(self.description.get('XTwosidedTicks', '0')))
-         out = ""
-         out += ('\n%\n% X-Ticks\n%\n')
-@@ -2265,7 +2265,7 @@ class XTicks(Ticks):
- 
- class YTicks(Ticks):
- 
--    def draw(self, custommajorticks=[], customminorticks=[], custommajortickmarks=-1, customminortickmarks=-1, drawlabels=True):
-+    def draw(self, custommajorticks=None, customminorticks=None, custommajortickmarks=-1, customminortickmarks=-1, drawlabels=True):
-         twosided = bool(int(self.description.get('YTwosidedTicks', '0')))
-         out = ""
-         out += ('\n%\n% Y-Ticks\n%\n')
-@@ -2320,7 +2320,7 @@ class ZTicks(Ticks):
-         self.description = description
-         self.coors = coors
- 
--    def draw(self, custommajorticks=[], customminorticks=[],
-+    def draw(self, custommajorticks=None, customminorticks=None,
-             custommajortickmarks=-1, customminortickmarks=-1,
-             drawlabels=True):
-         out = ""
diff --git a/nixpkgs/pkgs/development/libraries/polkit/default.nix b/nixpkgs/pkgs/development/libraries/polkit/default.nix
index f47d2713f1a4..fb16a7fb6939 100644
--- a/nixpkgs/pkgs/development/libraries/polkit/default.nix
+++ b/nixpkgs/pkgs/development/libraries/polkit/default.nix
@@ -1,5 +1,5 @@
 { stdenv, fetchurl, fetchpatch, autoreconfHook, pkgconfig, glib, expat, pam, perl
-, intltool, spidermonkey_52 , gobject-introspection, libxslt, docbook_xsl, dbus
+, intltool, spidermonkey_60 , gobject-introspection, libxslt, docbook_xsl, dbus
 , docbook_xml_dtd_412, gtk-doc, coreutils
 , useSystemd ? stdenv.isLinux, systemd
 , withGnome ? true
@@ -14,28 +14,14 @@ let
 in
 
 stdenv.mkDerivation rec {
-  name = "polkit-0.115";
+  pname = "polkit";
+  version = "0.116";
 
   src = fetchurl {
-    url = "https://www.freedesktop.org/software/polkit/releases/${name}.tar.gz";
-    sha256 = "0c91y61y4gy6p91cwbzg32dhavw4b7fflg370rimqhdxpzdfr1rg";
+    url = "https://www.freedesktop.org/software/${pname}/releases/${pname}-${version}.tar.gz";
+    sha256 = "1c9lbpndh5zis22f154vjrhnqw65z8s85nrgl42v738yf6g0q5w8";
   };
 
-  patches = [
-    # CVE-2019-6133 - See: https://bugs.chromium.org/p/project-zero/issues/detail?id=1692
-    (fetchpatch {
-      url = "https://gitlab.freedesktop.org/polkit/polkit/commit/6cc6aafee135ba44ea748250d7d29b562ca190e3.patch";
-      name = "CVE-2019-6133.patch";
-      sha256 = "0jjlbjzqcz96xh6w3nv3ss9jl0hhrcd7jg4aa5advf08ibaj29r1";
-    })
-    # CVE-2018-19788 - high UID fixup
-    (fetchpatch {
-      url = "https://gitlab.freedesktop.org/polkit/polkit/commit/5230646dc6876ef6e27f57926b1bad348f636147.patch";
-      name = "CVE-2018-19788.patch";
-      sha256 = "1y3az4mlxx8k1zcss5qm7k102s7k1kqgcfnf11j9678fh7p008vp";
-    })
-  ];
-
   postPatch = stdenv.lib.optionalString stdenv.isDarwin ''
     sed -i -e "s/-Wl,--as-needed//" configure.ac
   '';
@@ -46,7 +32,7 @@ stdenv.mkDerivation rec {
     [ glib gtk-doc pkgconfig intltool perl ]
     ++ [ libxslt docbook_xsl docbook_xml_dtd_412 ]; # man pages
   buildInputs =
-    [ glib expat pam spidermonkey_52 ]
+    [ glib expat pam spidermonkey_60 ]
     ++ stdenv.lib.optional useSystemd systemd
     ++ stdenv.lib.optional withGnome gobject-introspection;
 
@@ -72,15 +58,21 @@ stdenv.mkDerivation rec {
   configureFlags = [
     "--datadir=${system}/share"
     "--sysconfdir=/etc"
-    "--with-systemdsystemunitdir=$(out)/etc/systemd/system"
+    "--with-systemdsystemunitdir=${placeholder "out"}/etc/systemd/system"
     "--with-polkitd-user=polkituser" #TODO? <nixos> config.ids.uids.polkituser
     "--with-os-type=NixOS" # not recognized but prevents impurities on non-NixOS
     (if withGnome then "--enable-introspection" else "--disable-introspection")
   ] ++ stdenv.lib.optional (!doCheck) "--disable-test";
 
-  makeFlags = "INTROSPECTION_GIRDIR=$(out)/share/gir-1.0 INTROSPECTION_TYPELIBDIR=$(out)/lib/girepository-1.0";
+  makeFlags = [
+    "INTROSPECTION_GIRDIR=${placeholder "out"}/share/gir-1.0"
+    "INTROSPECTION_TYPELIBDIR=${placeholder "out"}/lib/girepository-1.0"
+  ];
 
-  installFlags=["datadir=$(out)/share" "sysconfdir=$(out)/etc"];
+  installFlags = [
+    "datadir=${placeholder "out"}/share"
+    "sysconfdir=${placeholder "out"}/etc"
+  ];
 
   inherit doCheck;
   checkInputs = [dbus];
diff --git a/nixpkgs/pkgs/development/libraries/portaudio/default.nix b/nixpkgs/pkgs/development/libraries/portaudio/default.nix
index 6a882ecd9003..89248597f5d9 100644
--- a/nixpkgs/pkgs/development/libraries/portaudio/default.nix
+++ b/nixpkgs/pkgs/development/libraries/portaudio/default.nix
@@ -15,6 +15,8 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--disable-mac-universal --enable-cxx" ];
 
+  NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.cc.isClang "-Wno-error=nullability-inferred-on-nested-type -Wno-error=nullability-completeness-on-arrays";
+
   propagatedBuildInputs = stdenv.lib.optionals stdenv.isDarwin [ AudioUnit AudioToolbox CoreAudio CoreServices Carbon ];
 
   patchPhase = stdenv.lib.optionalString stdenv.isDarwin ''
diff --git a/nixpkgs/pkgs/development/libraries/qscintilla/default.nix b/nixpkgs/pkgs/development/libraries/qscintilla/default.nix
index bc3b44413054..43f0e431bb15 100644
--- a/nixpkgs/pkgs/development/libraries/qscintilla/default.nix
+++ b/nixpkgs/pkgs/development/libraries/qscintilla/default.nix
@@ -1,6 +1,7 @@
 { stdenv, lib, fetchurl, unzip
 , qt4 ? null, qmake4Hook ? null
 , withQt5 ? false, qtbase ? null, qtmacextras ? null, qmake ? null
+, fixDarwinDylibNames
 }:
 
 # Fix Xcode 8 compilation problem
@@ -19,10 +20,13 @@ stdenv.mkDerivation rec {
     sha256 = "04678skipydx68zf52vznsfmll2v9aahr66g50lcqbr6xsmgr1yi";
   };
 
-  buildInputs = [ (if withQt5 then qtbase else qt4) ]
-    ++ lib.optional (withQt5 && stdenv.isDarwin) qtmacextras;
+  buildInputs = [ (if withQt5 then qtbase else qt4) ];
+
+  propagatedBuildInputs = lib.optional (withQt5 && stdenv.isDarwin) qtmacextras;
+
   nativeBuildInputs = [ unzip ]
-    ++ (if withQt5 then [ qmake ] else [ qmake4Hook ]);
+    ++ (if withQt5 then [ qmake ] else [ qmake4Hook ])
+    ++ lib.optional stdenv.isDarwin fixDarwinDylibNames;
 
 
   patches = lib.optional (stdenv.isDarwin && withQt5) [ xcodePatch ];
diff --git a/nixpkgs/pkgs/development/libraries/qt-4.x/4.8/default.nix b/nixpkgs/pkgs/development/libraries/qt-4.x/4.8/default.nix
index 8715aaaa44d0..de9a656f6ff1 100644
--- a/nixpkgs/pkgs/development/libraries/qt-4.x/4.8/default.nix
+++ b/nixpkgs/pkgs/development/libraries/qt-4.x/4.8/default.nix
@@ -231,5 +231,6 @@ stdenv.mkDerivation rec {
     license     = lib.licenses.lgpl21Plus; # or gpl3
     maintainers = with lib.maintainers; [ orivej lovek323 phreedom sander ];
     platforms   = lib.platforms.unix;
+    badPlatforms = [ "x86_64-darwin" ];
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/default.nix b/nixpkgs/pkgs/development/libraries/qt-5/5.11/default.nix
index 379c370e1fcc..0014a1452aa0 100644
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/default.nix
+++ b/nixpkgs/pkgs/development/libraries/qt-5/5.11/default.nix
@@ -20,7 +20,7 @@ top-level attribute to `top-level/all-packages.nix`.
   stdenv, fetchurl, fetchFromGitHub, makeSetupHook,
   bison, cups ? null, harfbuzz, libGL, perl,
   gstreamer, gst-plugins-base, gtk3, dconf,
-  cf-private,
+  cf-private, llvmPackages_5,
 
   # options
   developerBuild ? false,
@@ -51,34 +51,24 @@ let
   patches = {
     qtbase = [
       ./qtbase.patch
-      ./qtbase-darwin.patch
-      ./qtbase-revert-no-macos10.10.patch
       ./qtbase-fixguicmake.patch
-    ] ++ optionals stdenv.isDarwin [
-      ./qtbase-darwin-nseventtype.patch
-      ./qtbase-darwin-revert-69221.patch
     ];
     qtdeclarative = [ ./qtdeclarative.patch ];
     qtscript = [ ./qtscript.patch ];
     qtserialport = [ ./qtserialport.patch ];
     qttools = [ ./qttools.patch ];
-    qtwebengine = [ ./qtwebengine-no-build-skip.patch ]
-      ++ optional stdenv.cc.isClang ./qtwebengine-clang-fix.patch
-      ++ optionals stdenv.isDarwin [
-        ./qtwebengine-darwin-no-platform-check.patch
-        ./qtwebengine-darwin-sdk-10.10.patch
-        ./qtwebengine-darwin-old-sdk.patch
-      ];
-    qtwebkit = [ ./qtwebkit.patch ]
-      ++ optionals stdenv.isDarwin [
-        ./qtwebkit-darwin-no-readline.patch
-        ./qtwebkit-darwin-no-qos-classes.patch
-      ];
+    qtwebengine = [
+      ./qtwebengine-no-build-skip.patch
+      ./qtwebengine-darwin-no-platform-check.patch
+    ];
+    qtwebkit = [ ./qtwebkit.patch ];
   };
 
   mkDerivation =
-    import ../mkDerivation.nix
-    { inherit stdenv; inherit (stdenv) lib; }
+    import ../mkDerivation.nix {
+      inherit (stdenv) lib;
+      stdenv = if stdenv.cc.isClang then llvmPackages_5.stdenv else stdenv;
+    }
     { inherit debug; };
 
   qtModule =
@@ -109,7 +99,7 @@ let
       qtdoc = callPackage ../modules/qtdoc.nix {};
       qtgraphicaleffects = callPackage ../modules/qtgraphicaleffects.nix {};
       qtimageformats = callPackage ../modules/qtimageformats.nix {};
-      qtlocation = callPackage ../modules/qtlocation.nix {};
+      qtlocation = callPackage ../modules/qtlocation.nix { };
       qtmacextras = callPackage ../modules/qtmacextras.nix {
         inherit cf-private;
       };
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin-nseventtype.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin-nseventtype.patch
deleted file mode 100644
index 9ef6e8ef0692..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin-nseventtype.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/src/plugins/platforms/cocoa/qcocoawindow.mm
-+++ b/src/plugins/platforms/cocoa/qcocoawindow.mm
-@@ -404,8 +404,8 @@ void QCocoaWindow::setVisible(bool visible)
-                         removeMonitor();
-                         monitor = [NSEvent addGlobalMonitorForEventsMatchingMask:NSLeftMouseDownMask|NSRightMouseDownMask|NSOtherMouseDownMask|NSMouseMovedMask handler:^(NSEvent *e) {
-                             QPointF localPoint = QCocoaScreen::mapFromNative([NSEvent mouseLocation]);
--                            const auto button = e.type == NSEventTypeMouseMoved ? Qt::NoButton : cocoaButton2QtButton([e buttonNumber]);
--                            const auto eventType = e.type == NSEventTypeMouseMoved ? QEvent::MouseMove : QEvent::MouseButtonPress;
-+                            const auto button = e.type == NSMouseMoved ? Qt::NoButton : cocoaButton2QtButton([e buttonNumber]);
-+                            const auto eventType = e.type == NSMouseMoved ? QEvent::MouseMove : QEvent::MouseButtonPress;
-                             QWindowSystemInterface::handleMouseEvent(window(), window()->mapFromGlobal(localPoint.toPoint()), localPoint,
-                                                                      Qt::MouseButtons(uint(NSEvent.pressedMouseButtons & 0xFFFF)), button, eventType);
-                         }];
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin-revert-69221.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin-revert-69221.patch
deleted file mode 100644
index 73eea435f847..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin-revert-69221.patch
+++ /dev/null
@@ -1,73 +0,0 @@
-diff --git a/src/plugins/platforms/cocoa/qcocoawindow.mm b/src/plugins/platforms/cocoa/qcocoawindow.mm
-index 00c3f7c22c..94d35f59d6 100644
---- a/src/plugins/platforms/cocoa/qcocoawindow.mm
-+++ b/src/plugins/platforms/cocoa/qcocoawindow.mm
-@@ -1355,15 +1355,6 @@ QCocoaNSWindow *QCocoaWindow::createNSWindow(bool shouldBePanel)
- {
-     QMacAutoReleasePool pool;
- 
--    Qt::WindowType type = window()->type();
--    Qt::WindowFlags flags = window()->flags();
--
--    // Note: The macOS window manager has a bug, where if a screen is rotated, it will not allow
--    // a window to be created within the area of the screen that has a Y coordinate (I quadrant)
--    // higher than the height of the screen  in its non-rotated state, unless the window is
--    // created with the NSWindowStyleMaskBorderless style mask.
--    NSWindowStyleMask styleMask = windowStyleMask(flags);
--
-     QRect rect = geometry();
- 
-     QScreen *targetScreen = nullptr;
-@@ -1375,22 +1366,26 @@ QCocoaNSWindow *QCocoaWindow::createNSWindow(bool shouldBePanel)
-     }
- 
-     if (!targetScreen) {
--        qCWarning(lcQpaCocoaWindow) << "Window position" << rect << "outside any known screen, using primary screen";
-+        qCWarning(lcQpaCocoaWindow) << "Window position outside any known screen, using primary screen";
-         targetScreen = QGuiApplication::primaryScreen();
--        // AppKit will only reposition a window that's outside the target screen area if
--        // the window has a title bar. If left out, the window ends up with no screen.
--        // The style mask will be corrected to the original style mask in setWindowFlags.
--        styleMask |= NSWindowStyleMaskTitled;
-     }
- 
-     rect.translate(-targetScreen->geometry().topLeft());
-     QCocoaScreen *cocoaScreen = static_cast<QCocoaScreen *>(targetScreen->handle());
-     NSRect frame = QCocoaScreen::mapToNative(rect, cocoaScreen);
- 
-+    // Note: The macOS window manager has a bug, where if a screen is rotated, it will not allow
-+    // a window to be created within the area of the screen that has a Y coordinate (I quadrant)
-+    // higher than the height of the screen  in its non-rotated state, unless the window is
-+    // created with the NSWindowStyleMaskBorderless style mask.
-+
-+    Qt::WindowType type = window()->type();
-+    Qt::WindowFlags flags = window()->flags();
-+
-     // Create NSWindow
-     Class windowClass = shouldBePanel ? [QNSPanel class] : [QNSWindow class];
-     QCocoaNSWindow *nsWindow = [[windowClass alloc] initWithContentRect:frame
--        styleMask:styleMask
-+        styleMask:windowStyleMask(flags)
-         // Deferring window creation breaks OpenGL (the GL context is
-         // set up before the window is shown and needs a proper window)
-         backing:NSBackingStoreBuffered defer:NO
-@@ -1399,9 +1394,6 @@ QCocoaNSWindow *QCocoaWindow::createNSWindow(bool shouldBePanel)
-     Q_ASSERT_X(nsWindow.screen == cocoaScreen->nativeScreen(), "QCocoaWindow",
-         "Resulting NSScreen should match the requested NSScreen");
- 
--    if (targetScreen != window()->screen())
--        QWindowSystemInterface::handleWindowScreenChanged(window(), targetScreen);
--
-     nsWindow.delegate = [[QNSWindowDelegate alloc] initWithQCocoaWindow:this];
- 
-     // Prevent Cocoa from releasing the window on close. Qt
-@@ -1421,6 +1413,9 @@ QCocoaNSWindow *QCocoaWindow::createNSWindow(bool shouldBePanel)
-         });
-     }
- 
-+    if (targetScreen != window()->screen())
-+        QWindowSystemInterface::handleWindowScreenChanged(window(), targetScreen);
-+
-     nsWindow.restorable = NO;
-     nsWindow.level = windowLevel(flags);
- 
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin.patch
deleted file mode 100644
index f66351752054..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-darwin.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-diff --git a/src/plugins/bearer/corewlan/qcorewlanengine.mm b/src/plugins/bearer/corewlan/qcorewlanengine.mm
-index 341d3bccf2..3368234c26 100644
---- a/src/plugins/bearer/corewlan/qcorewlanengine.mm
-+++ b/src/plugins/bearer/corewlan/qcorewlanengine.mm
-@@ -287,7 +287,7 @@ void QScanThread::getUserConfigurations()
-     QMacAutoReleasePool pool;
-     userProfiles.clear();
- 
--    NSArray<NSString *> *wifiInterfaces = [CWWiFiClient interfaceNames];
-+    NSArray *wifiInterfaces = [CWWiFiClient interfaceNames];
-     for (NSString *ifName in wifiInterfaces) {
- 
-         CWInterface *wifiInterface = [[CWWiFiClient sharedWiFiClient] interfaceWithName:ifName];
-@@ -602,7 +602,7 @@ void QCoreWlanEngine::doRequestUpdate()
- 
-     QMacAutoReleasePool pool;
- 
--    NSArray<NSString *> *wifiInterfaces = [CWWiFiClient interfaceNames];
-+    NSArray *wifiInterfaces = [CWWiFiClient interfaceNames];
-     for (NSString *ifName in wifiInterfaces) {
-             scanThread->interfaceName = QString::fromNSString(ifName);
-             scanThread->start();
-diff --git a/src/plugins/platforms/cocoa/qcocoascreen.mm b/src/plugins/platforms/cocoa/qcocoascreen.mm
-index a17a02b629..d76c42fa03 100644
---- a/src/plugins/platforms/cocoa/qcocoascreen.mm
-+++ b/src/plugins/platforms/cocoa/qcocoascreen.mm
-@@ -114,7 +114,7 @@ void QCocoaScreen::updateGeometry()
-         return;
-
-     // The reference screen for the geometry is always the primary screen
--    QRectF primaryScreenGeometry = QRectF::fromCGRect([[NSScreen screens] firstObject].frame);
-+    QRectF primaryScreenGeometry = QRectF::fromCGRect([[[NSScreen screens] firstObject] frame]);
-     m_geometry = qt_mac_flip(QRectF::fromCGRect(nsScreen.frame), primaryScreenGeometry).toRect();
-     m_availableGeometry = qt_mac_flip(QRectF::fromCGRect(nsScreen.visibleFrame), primaryScreenGeometry).toRect();
-
-diff --git a/src/plugins/platforms/cocoa/qcocoawindow.mm b/src/plugins/platforms/cocoa/qcocoawindow.mm
-index 72f3bc0075..a9c058a850 100644
---- a/src/plugins/platforms/cocoa/qcocoawindow.mm
-+++ b/src/plugins/platforms/cocoa/qcocoawindow.mm
-@@ -1676,7 +1676,7 @@ void QCocoaWindow::applyContentBorderThickness(NSWindow *window)
- 
-     if (!m_drawContentBorderGradient) {
-         window.styleMask = window.styleMask & ~NSTexturedBackgroundWindowMask;
--        [window.contentView.superview setNeedsDisplay:YES];
-+        [[window.contentView superview] setNeedsDisplay:YES];
-         window.titlebarAppearsTransparent = NO;
-         return;
-     }
-diff --git a/src/plugins/platforms/cocoa/qnswindow.mm b/src/plugins/platforms/cocoa/qnswindow.mm
-index cb13b7d184..0159d68dca 100644
---- a/src/plugins/platforms/cocoa/qnswindow.mm
-+++ b/src/plugins/platforms/cocoa/qnswindow.mm
-@@ -231,7 +231,7 @@ static bool isMouseEvent(NSEvent *ev)
-     if (pw->frameStrutEventsEnabled() && isMouseEvent(theEvent)) {
-         NSPoint loc = [theEvent locationInWindow];
-         NSRect windowFrame = [self convertRectFromScreen:self.frame];
--        NSRect contentFrame = self.contentView.frame;
-+        NSRect contentFrame = [self.contentView frame];
-         if (NSMouseInRect(loc, windowFrame, NO) && !NSMouseInRect(loc, contentFrame, NO))
-             [qnsview_cast(pw->view()) handleFrameStrutMouseEvent:theEvent];
-     }
-@@ -260,7 +260,7 @@ static bool isMouseEvent(NSEvent *ev)
- + (void)applicationActivationChanged:(NSNotification*)notification
- {
-     const id sender = self;
--    NSEnumerator<NSWindow*> *windowEnumerator = nullptr;
-+    NSEnumerator *windowEnumerator = nullptr;
-     NSApplication *application = [NSApplication sharedApplication];
- 
- #if QT_MACOS_PLATFORM_SDK_EQUAL_OR_ABOVE(__MAC_10_12)
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-revert-no-macos10.10.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-revert-no-macos10.10.patch
deleted file mode 100644
index 29776518379d..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtbase-revert-no-macos10.10.patch
+++ /dev/null
@@ -1,102 +0,0 @@
-Revert "Remove code paths for macOS < 10.11"
-
-This reverts commit 138a65e0cfa80b13fd018a01e7d8b33341a3cfd3.
-
-From 138a65e0cfa80b13fd018a01e7d8b33341a3cfd3 Mon Sep 17 00:00:00 2001
-From: Jake Petroules <jake.petroules@qt.io>
-Date: Thu, 8 Feb 2018 11:05:42 -0800
-Subject: [PATCH] Remove code paths for macOS < 10.11
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Change-Id: I5ae02d88aa3dcd97d1f2ebf6255a68643e5d6daa
-Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
-Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
-Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
----
- .../fontdatabases/mac/qfontengine_coretext.mm            | 16 +++-------------
- src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm    |  6 +-----
- src/plugins/platforms/cocoa/qnswindowdelegate.mm         | 16 ----------------
- 3 files changed, 4 insertions(+), 34 deletions(-)
-
-diff --git a/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm b/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
-index 98b753eff9..489d9cd031 100644
---- a/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
-+++ b/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
-@@ -47,18 +47,28 @@
- 
- #include <cmath>
- 
--#if defined(Q_OS_MACOS)
-+#if defined(Q_OS_OSX) && !QT_OSX_DEPLOYMENT_TARGET_BELOW(__MAC_10_11)
- #import <AppKit/AppKit.h>
- #endif
- 
--#if defined(QT_PLATFORM_UIKIT)
-+#if defined(QT_PLATFORM_UIKIT) && !QT_IOS_DEPLOYMENT_TARGET_BELOW(__IPHONE_8_2)
- #import <UIKit/UIKit.h>
- #endif
- 
- // These are available cross platform, exported as kCTFontWeightXXX from CoreText.framework,
- // but they are not documented and are not in public headers so are private API and exposed
- // only through the NSFontWeightXXX and UIFontWeightXXX aliases in AppKit and UIKit (rdar://26109857)
--#if defined(Q_OS_MACOS)
-+#if QT_MAC_DEPLOYMENT_TARGET_BELOW(__MAC_10_11, __IPHONE_8_2)
-+#define kCTFontWeightUltraLight -0.8
-+#define kCTFontWeightThin -0.6
-+#define kCTFontWeightLight -0.4
-+#define kCTFontWeightRegular 0
-+#define kCTFontWeightMedium 0.23
-+#define kCTFontWeightSemibold 0.3
-+#define kCTFontWeightBold 0.4
-+#define kCTFontWeightHeavy 0.56
-+#define kCTFontWeightBlack 0.62
-+#elif defined(Q_OS_OSX)
- #define kCTFontWeightUltraLight NSFontWeightUltraLight
- #define kCTFontWeightThin NSFontWeightThin
- #define kCTFontWeightLight NSFontWeightLight
-diff --git a/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm b/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
-index 94f2125bad..272cd9f3dc 100644
---- a/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
-+++ b/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
-@@ -162,7 +162,11 @@ QT_NAMESPACE_ALIAS_OBJC_CLASS(QNSOpenSavePanelDelegate);
-     // resetting our mCurrentDir, set the delegate
-     // here to make sure it gets the correct value.
-     [mSavePanel setDelegate:self];
--    mOpenPanel.accessoryViewDisclosed = YES;
-+
-+#if QT_OSX_PLATFORM_SDK_EQUAL_OR_ABOVE(__MAC_10_11)
-+    if (__builtin_available(macOS 10.11, *))
-+        mOpenPanel.accessoryViewDisclosed = YES;
-+#endif
- 
-     if (mOptions->isLabelExplicitlySet(QFileDialogOptions::Accept))
-         [mSavePanel setPrompt:[self strip:options->labelText(QFileDialogOptions::Accept)]];
-diff --git a/src/plugins/platforms/cocoa/qnswindowdelegate.mm b/src/plugins/platforms/cocoa/qnswindowdelegate.mm
-index 057a4c2943..eb55e50622 100644
---- a/src/plugins/platforms/cocoa/qnswindowdelegate.mm
-+++ b/src/plugins/platforms/cocoa/qnswindowdelegate.mm
-@@ -103,6 +103,22 @@ static QRegExp whitespaceRegex = QRegExp(QStringLiteral("\\s*"));
-     return QCocoaScreen::mapToNative(maximizedFrame);
- }
- 
-+#if QT_MACOS_DEPLOYMENT_TARGET_BELOW(__MAC_10_11)
-+/*
-+    AppKit on OS X 10.10 wrongly calls windowWillUseStandardFrame:defaultFrame
-+    from -[NSWindow _frameForFullScreenMode] when going into fullscreen, resulting
-+    in black bars on top and bottom of the window. By implementing the following
-+    method, AppKit will choose that instead, and resolve the right fullscreen
-+    geometry.
-+*/
-+- (NSSize)window:(NSWindow *)window willUseFullScreenContentSize:(NSSize)proposedSize
-+{
-+    Q_UNUSED(proposedSize);
-+    Q_ASSERT(window == m_cocoaWindow->nativeWindow());
-+    return NSSizeFromCGSize(m_cocoaWindow->screen()->geometry().size().toCGSize());
-+}
-+#endif
-+
- - (BOOL)window:(NSWindow *)window shouldPopUpDocumentPathMenu:(NSMenu *)menu
- {
-     Q_UNUSED(window);
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-clang-fix.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-clang-fix.patch
deleted file mode 100644
index 8dafd65cd343..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-clang-fix.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-Fix a following build error:
-
-In file included from ../../3rdparty/chromium/device/bluetooth/bluetooth_remote_gatt_characteristic_mac.mm:7:
-../../3rdparty/chromium/base/bind.h:59:3: error: static_assert failed "Bound argument |i| of type |Arg| cannot be forwarded as |Unwrapped| to the bound functor, which declares it as |Param|."
-  static_assert(
-  ^
-../../3rdparty/chromium/base/bind.h:91:7: note: in instantiation of template class 'base::internal::AssertConstructible<1, long, long, const long &, NSError *>' requested here
-    : AssertConstructible<Ns, Args, std::decay_t<Args>, Unwrapped, Params>... {
-      ^
-../../3rdparty/chromium/base/bind.h:213:27: note: in instantiation of template class 'base::internal::AssertBindArgsValidity<std::__1::integer_sequence<unsigned long, 0, 1>, base::internal::TypeList<base::WeakPtr<device::BluetoothRemoteGattCharacteristicMac>, long>, base::internal::TypeList<device::BluetoothRemoteGattCharacteristicMac *, const long &>, base::internal::TypeList<device::BluetoothRemoteGattCharacteristicMac *, NSError *> >' requested here
-  static_assert(internal::AssertBindArgsValidity<
-                          ^
-../../3rdparty/chromium/base/bind.h:242:16: note: in instantiation of function template specialization 'base::BindRepeating<void (device::BluetoothRemoteGattCharacteristicMac::*)(NSError *), base::WeakPtr<device::BluetoothRemoteGattCharacteristicMac>, long>' requested here
-  return base::BindRepeating(std::forward<Functor>(functor),
-               ^
-../../3rdparty/chromium/device/bluetooth/bluetooth_remote_gatt_characteristic_mac.mm:211:15: note: in instantiation of function template specialization 'base::Bind<void (device::BluetoothRemoteGattCharacteristicMac::*)(NSError *), base::WeakPtr<device::BluetoothRemoteGattCharacteristicMac>, long>' requested here
-        base::Bind(&BluetoothRemoteGattCharacteristicMac::DidWriteValue,
-              ^
-
---- a/src/3rdparty/chromium/device/bluetooth/bluetooth_remote_gatt_characteristic_mac.mm
-+++ b/src/3rdparty/chromium/device/bluetooth/bluetooth_remote_gatt_characteristic_mac.mm
-@@ -209,7 +209,7 @@ void BluetoothRemoteGattCharacteristicMac::WriteRemoteCharacteristic(
-     base::ThreadTaskRunnerHandle::Get()->PostTask(
-         FROM_HERE,
-         base::Bind(&BluetoothRemoteGattCharacteristicMac::DidWriteValue,
--                   weak_ptr_factory_.GetWeakPtr(), nil));
-+                   weak_ptr_factory_.GetWeakPtr(), nullptr));
-   }
- }
- 
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-darwin-old-sdk.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-darwin-old-sdk.patch
deleted file mode 100644
index b065c2211017..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-darwin-old-sdk.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-diff --git a/src/3rdparty/chromium/third_party/webrtc/sdk/objc/Framework/Classes/Common/RTCFieldTrials.mm b/src/3rdparty/chromium/third_party/webrtc/sdk/objc/Framework/Classes/Common/RTCFieldTrials.mm
---- a/src/3rdparty/chromium/third_party/webrtc/sdk/objc/Framework/Classes/Common/RTCFieldTrials.mm
-+++ b/src/3rdparty/chromium/third_party/webrtc/sdk/objc/Framework/Classes/Common/RTCFieldTrials.mm
-@@ -45,7 +45,7 @@ NSString *RTCFieldTrialTrendlineFilterValue(
-   return [NSString stringWithFormat:format, windowSize, smoothingCoeff, thresholdGain];
- }
- 
--void RTCInitFieldTrialDictionary(NSDictionary<NSString *, NSString *> *fieldTrials) {
-+void RTCInitFieldTrialDictionary(NSDictionary *fieldTrials) {
-   if (!fieldTrials) {
-     RTCLogWarning(@"No fieldTrials provided.");
-     return;
-diff --git a/src/3rdparty/chromium/third_party/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCFieldTrials.h b/src/3rdparty/chromium/third_party/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCFieldTrials.h
---- a/src/3rdparty/chromium/third_party/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCFieldTrials.h
-+++ b/src/3rdparty/chromium/third_party/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCFieldTrials.h
-@@ -40,4 +40,4 @@ RTC_EXTERN NSString *RTCFieldTrialTrendlineFilterValue(
-  *  Must be called before any other call into WebRTC. See:
-  *  webrtc/system_wrappers/include/field_trial_default.h
-  */
--RTC_EXTERN void RTCInitFieldTrialDictionary(NSDictionary<NSString *, NSString *> *fieldTrials);
-+RTC_EXTERN void RTCInitFieldTrialDictionary(NSDictionary *fieldTrials);
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-darwin-sdk-10.10.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-darwin-sdk-10.10.patch
deleted file mode 100644
index d43b09b95383..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebengine-darwin-sdk-10.10.patch
+++ /dev/null
@@ -1,160 +0,0 @@
-Fix build against 10.10 SDK
-
-The SecKey part perhaps could be fixed by implementing a revert to
-https://chromium.googlesource.com/chromium/src.git/+/8418e098b9cbedf884878b61dcd3292c515845cf%5E%21/#F0
-
---- a/src/3rdparty/chromium/content/browser/renderer_host/input/web_input_event_builders_mac.mm
-+++ b/src/3rdparty/chromium/content/browser/renderer_host/input/web_input_event_builders_mac.mm
-@@ -1,3 +1,4 @@
-+#define NSEventTypeScrollWheel 22
- // Copyright 2015 The Chromium Authors. All rights reserved.
- // Use of this source code is governed by a BSD-style license that can be
- // found in the LICENSE file.
---- a/src/3rdparty/chromium/net/ssl/ssl_platform_key_mac.cc
-+++ b/src/3rdparty/chromium/net/ssl/ssl_platform_key_mac.cc
-@@ -48,21 +48,6 @@ namespace net {
- 
- namespace {
- 
--// TODO(davidben): Remove this when we switch to building to the 10.13
--// SDK. https://crbug.com/780980
--#if !defined(MAC_OS_X_VERSION_10_13) || \
--    MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_13
--API_AVAILABLE(macosx(10.13))
--const SecKeyAlgorithm kSecKeyAlgorithmRSASignatureDigestPSSSHA256 =
--    CFSTR("algid:sign:RSA:digest-PSS:SHA256:SHA256:32");
--API_AVAILABLE(macosx(10.13))
--const SecKeyAlgorithm kSecKeyAlgorithmRSASignatureDigestPSSSHA384 =
--    CFSTR("algid:sign:RSA:digest-PSS:SHA384:SHA384:48");
--API_AVAILABLE(macosx(10.13))
--const SecKeyAlgorithm kSecKeyAlgorithmRSASignatureDigestPSSSHA512 =
--    CFSTR("algid:sign:RSA:digest-PSS:SHA512:SHA512:64");
--#endif
--
- class ScopedCSSM_CC_HANDLE {
-  public:
-   ScopedCSSM_CC_HANDLE() : handle_(0) {}
-@@ -187,109 +172,6 @@ class SSLPlatformKeyCSSM : public ThreadedSSLPrivateKey::Delegate {
-   DISALLOW_COPY_AND_ASSIGN(SSLPlatformKeyCSSM);
- };
- 
--// Returns the corresponding SecKeyAlgorithm or nullptr if unrecognized.
--API_AVAILABLE(macosx(10.12))
--SecKeyAlgorithm GetSecKeyAlgorithm(uint16_t algorithm) {
--  switch (algorithm) {
--    case SSL_SIGN_RSA_PKCS1_SHA512:
--      return kSecKeyAlgorithmRSASignatureDigestPKCS1v15SHA512;
--    case SSL_SIGN_RSA_PKCS1_SHA384:
--      return kSecKeyAlgorithmRSASignatureDigestPKCS1v15SHA384;
--    case SSL_SIGN_RSA_PKCS1_SHA256:
--      return kSecKeyAlgorithmRSASignatureDigestPKCS1v15SHA256;
--    case SSL_SIGN_RSA_PKCS1_SHA1:
--      return kSecKeyAlgorithmRSASignatureDigestPKCS1v15SHA1;
--    case SSL_SIGN_RSA_PKCS1_MD5_SHA1:
--      return kSecKeyAlgorithmRSASignatureDigestPKCS1v15Raw;
--    case SSL_SIGN_ECDSA_SECP521R1_SHA512:
--      return kSecKeyAlgorithmECDSASignatureDigestX962SHA512;
--    case SSL_SIGN_ECDSA_SECP384R1_SHA384:
--      return kSecKeyAlgorithmECDSASignatureDigestX962SHA384;
--    case SSL_SIGN_ECDSA_SECP256R1_SHA256:
--      return kSecKeyAlgorithmECDSASignatureDigestX962SHA256;
--    case SSL_SIGN_ECDSA_SHA1:
--      return kSecKeyAlgorithmECDSASignatureDigestX962SHA1;
--  }
--
--  if (base::mac::IsAtLeastOS10_13()) {
--    switch (algorithm) {
--      case SSL_SIGN_RSA_PSS_SHA512:
--        return kSecKeyAlgorithmRSASignatureDigestPSSSHA512;
--      case SSL_SIGN_RSA_PSS_SHA384:
--        return kSecKeyAlgorithmRSASignatureDigestPSSSHA384;
--      case SSL_SIGN_RSA_PSS_SHA256:
--        return kSecKeyAlgorithmRSASignatureDigestPSSSHA256;
--    }
--  }
--
--  return nullptr;
--}
--
--class API_AVAILABLE(macosx(10.12)) SSLPlatformKeySecKey
--    : public ThreadedSSLPrivateKey::Delegate {
-- public:
--  SSLPlatformKeySecKey(int type, size_t max_length, SecKeyRef key)
--      : key_(key, base::scoped_policy::RETAIN) {
--    // Determine the algorithms supported by the key.
--    for (uint16_t algorithm : SSLPrivateKey::DefaultAlgorithmPreferences(
--             type, true /* include PSS */)) {
--      SecKeyAlgorithm sec_algorithm = GetSecKeyAlgorithm(algorithm);
--      if (sec_algorithm &&
--          SecKeyIsAlgorithmSupported(key_.get(), kSecKeyOperationTypeSign,
--                                     sec_algorithm)) {
--        preferences_.push_back(algorithm);
--      }
--    }
--  }
--
--  ~SSLPlatformKeySecKey() override {}
--
--  std::vector<uint16_t> GetAlgorithmPreferences() override {
--    return preferences_;
--  }
--
--  Error Sign(uint16_t algorithm,
--             base::span<const uint8_t> input,
--             std::vector<uint8_t>* signature) override {
--    SecKeyAlgorithm sec_algorithm = GetSecKeyAlgorithm(algorithm);
--    if (!sec_algorithm) {
--      NOTREACHED();
--      return ERR_FAILED;
--    }
--
--    const EVP_MD* md = SSL_get_signature_algorithm_digest(algorithm);
--    uint8_t digest[EVP_MAX_MD_SIZE];
--    unsigned digest_len;
--    if (!md || !EVP_Digest(input.data(), input.size(), digest, &digest_len, md,
--                           nullptr)) {
--      return ERR_SSL_CLIENT_AUTH_SIGNATURE_FAILED;
--    }
--
--    base::ScopedCFTypeRef<CFDataRef> digest_ref(CFDataCreateWithBytesNoCopy(
--        kCFAllocatorDefault, digest, base::checked_cast<CFIndex>(digest_len),
--        kCFAllocatorNull));
--
--    base::ScopedCFTypeRef<CFErrorRef> error;
--    base::ScopedCFTypeRef<CFDataRef> signature_ref(SecKeyCreateSignature(
--        key_, sec_algorithm, digest_ref, error.InitializeInto()));
--    if (!signature_ref) {
--      LOG(ERROR) << error;
--      return ERR_SSL_CLIENT_AUTH_SIGNATURE_FAILED;
--    }
--
--    signature->assign(
--        CFDataGetBytePtr(signature_ref),
--        CFDataGetBytePtr(signature_ref) + CFDataGetLength(signature_ref));
--    return OK;
--  }
--
-- private:
--  std::vector<uint16_t> preferences_;
--  base::ScopedCFTypeRef<SecKeyRef> key_;
--
--  DISALLOW_COPY_AND_ASSIGN(SSLPlatformKeySecKey);
--};
--
- scoped_refptr<SSLPrivateKey> CreateSSLPrivateKeyForSecKey(
-     const X509Certificate* certificate,
-     SecKeyRef private_key) {
-@@ -298,13 +180,6 @@ scoped_refptr<SSLPrivateKey> CreateSSLPrivateKeyForSecKey(
-   if (!GetClientCertInfo(certificate, &key_type, &max_length))
-     return nullptr;
- 
--  if (base::mac::IsAtLeastOS10_12()) {
--    return base::MakeRefCounted<ThreadedSSLPrivateKey>(
--        std::make_unique<SSLPlatformKeySecKey>(key_type, max_length,
--                                               private_key),
--        GetSSLPlatformKeyTaskRunner());
--  }
--
-   const CSSM_KEY* cssm_key;
-   OSStatus status = SecKeyGetCSSMKey(private_key, &cssm_key);
-   if (status != noErr) {
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebkit-darwin-no-qos-classes.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebkit-darwin-no-qos-classes.patch
deleted file mode 100644
index a7087f517623..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebkit-darwin-no-qos-classes.patch
+++ /dev/null
@@ -1,11 +0,0 @@
-diff --git a/Source/cmake/OptionsQt.cmake b/Source/cmake/OptionsQt.cmake
---- a/Source/cmake/OptionsQt.cmake
-+++ b/Source/cmake/OptionsQt.cmake
-@@ -683,7 +683,6 @@ if (WIN32 AND COMPILER_IS_GCC_OR_CLANG)
- endif ()
- 
- if (APPLE)
--    SET_AND_EXPOSE_TO_BUILD(HAVE_QOS_CLASSES 1)
- endif ()
- 
- if (ENABLE_MATHML)
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebkit-darwin-no-readline.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebkit-darwin-no-readline.patch
deleted file mode 100644
index 26d189d86019..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.11/qtwebkit-darwin-no-readline.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-diff --git a/Source/JavaScriptCore/shell/CMakeLists.txt b/Source/JavaScriptCore/shell/CMakeLists.txt
---- a/Source/JavaScriptCore/shell/CMakeLists.txt
-+++ b/Source/JavaScriptCore/shell/CMakeLists.txt
-@@ -9,7 +9,6 @@ set(JSC_LIBRARIES
- )
- 
- if (WTF_OS_MAC_OS_X)
--    list(APPEND JSC_LIBRARIES edit)
- endif ()
- 
- if ("${JavaScriptCore_LIBRARY_TYPE}" MATCHES "STATIC")
-diff --git a/Source/WTF/wtf/Platform.h b/Source/WTF/wtf/Platform.h
---- a/Source/WTF/wtf/Platform.h
-+++ b/Source/WTF/wtf/Platform.h
-@@ -563,7 +563,6 @@
- #if PLATFORM(IOS)
- 
- #define HAVE_NETWORK_EXTENSION 1
--#define HAVE_READLINE 1
- #if USE(APPLE_INTERNAL_SDK)
- #define USE_CFNETWORK 1
- #endif
-@@ -650,7 +649,6 @@
- #define HAVE_MADV_DONTNEED 1
- #define HAVE_MERGESORT 1
- #define HAVE_PTHREAD_SETNAME_NP 1
--#define HAVE_READLINE 1
- #define HAVE_SYS_TIMEB_H 1
- 
- #if !PLATFORM(GTK) && !PLATFORM(QT)
-diff --git a/Source/WTF/wtf/PlatformMac.cmake b/Source/WTF/wtf/PlatformMac.cmake
---- a/Source/WTF/wtf/PlatformMac.cmake
-+++ b/Source/WTF/wtf/PlatformMac.cmake
-@@ -2,11 +2,9 @@ set(WTF_LIBRARY_TYPE SHARED)
- 
- find_library(COCOA_LIBRARY Cocoa)
- find_library(COREFOUNDATION_LIBRARY CoreFoundation)
--find_library(READLINE_LIBRARY Readline)
- list(APPEND WTF_LIBRARIES
-     ${COREFOUNDATION_LIBRARY}
-     ${COCOA_LIBRARY}
--    ${READLINE_LIBRARY}
-     libicucore.dylib
- )
- 
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.12/default.nix b/nixpkgs/pkgs/development/libraries/qt-5/5.12/default.nix
index 6d0e241d7a54..d84596bd0544 100644
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.12/default.nix
+++ b/nixpkgs/pkgs/development/libraries/qt-5/5.12/default.nix
@@ -20,7 +20,7 @@ top-level attribute to `top-level/all-packages.nix`.
   stdenv, fetchurl, fetchFromGitHub, makeSetupHook,
   bison, cups ? null, harfbuzz, libGL, perl,
   gstreamer, gst-plugins-base, gtk3, dconf,
-  cf-private,
+  cf-private, llvmPackages_5,
 
   # options
   developerBuild ? false,
@@ -51,11 +51,7 @@ let
   patches = {
     qtbase = [
       ./qtbase.patch
-      ./qtbase-darwin.patch
-      ./qtbase-revert-no-macos10.10.patch
       ./qtbase-fixguicmake.patch
-    ] ++ optionals stdenv.isDarwin [
-      ./qtbase-darwin-nseventtype.patch
     ];
     qtdeclarative = [ ./qtdeclarative.patch ];
     qtscript = [ ./qtscript.patch ];
@@ -73,8 +69,10 @@ let
   };
 
   mkDerivation =
-    import ../mkDerivation.nix
-    { inherit stdenv; inherit (stdenv) lib; }
+    import ../mkDerivation.nix {
+      inherit (stdenv) lib;
+      stdenv = if stdenv.cc.isClang then llvmPackages_5.stdenv else stdenv;
+    }
     { inherit debug; };
 
   qtModule =
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-darwin-nseventtype.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-darwin-nseventtype.patch
deleted file mode 100644
index 9ef6e8ef0692..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-darwin-nseventtype.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/src/plugins/platforms/cocoa/qcocoawindow.mm
-+++ b/src/plugins/platforms/cocoa/qcocoawindow.mm
-@@ -404,8 +404,8 @@ void QCocoaWindow::setVisible(bool visible)
-                         removeMonitor();
-                         monitor = [NSEvent addGlobalMonitorForEventsMatchingMask:NSLeftMouseDownMask|NSRightMouseDownMask|NSOtherMouseDownMask|NSMouseMovedMask handler:^(NSEvent *e) {
-                             QPointF localPoint = QCocoaScreen::mapFromNative([NSEvent mouseLocation]);
--                            const auto button = e.type == NSEventTypeMouseMoved ? Qt::NoButton : cocoaButton2QtButton([e buttonNumber]);
--                            const auto eventType = e.type == NSEventTypeMouseMoved ? QEvent::MouseMove : QEvent::MouseButtonPress;
-+                            const auto button = e.type == NSMouseMoved ? Qt::NoButton : cocoaButton2QtButton([e buttonNumber]);
-+                            const auto eventType = e.type == NSMouseMoved ? QEvent::MouseMove : QEvent::MouseButtonPress;
-                             QWindowSystemInterface::handleMouseEvent(window(), window()->mapFromGlobal(localPoint.toPoint()), localPoint,
-                                                                      Qt::MouseButtons(uint(NSEvent.pressedMouseButtons & 0xFFFF)), button, eventType);
-                         }];
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-darwin.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-darwin.patch
deleted file mode 100644
index 7ce27a99758e..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-darwin.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-diff --git a/src/plugins/bearer/corewlan/qcorewlanengine.mm b/src/plugins/bearer/corewlan/qcorewlanengine.mm
-index c3dd49ff3e..6871399817 100644
---- a/src/plugins/bearer/corewlan/qcorewlanengine.mm
-+++ b/src/plugins/bearer/corewlan/qcorewlanengine.mm
-@@ -283,7 +283,7 @@ void QScanThread::getUserConfigurations()
-     QMacAutoReleasePool pool;
-     userProfiles.clear();
- 
--    NSArray<NSString *> *wifiInterfaces = [CWWiFiClient interfaceNames];
-+    NSArray *wifiInterfaces = [CWWiFiClient interfaceNames];
-     for (NSString *ifName in wifiInterfaces) {
- 
-         CWInterface *wifiInterface = [[CWWiFiClient sharedWiFiClient] interfaceWithName:ifName];
-@@ -598,7 +598,7 @@ void QCoreWlanEngine::doRequestUpdate()
- 
-     QMacAutoReleasePool pool;
- 
--    NSArray<NSString *> *wifiInterfaces = [CWWiFiClient interfaceNames];
-+    NSArray *wifiInterfaces = [CWWiFiClient interfaceNames];
-     for (NSString *ifName in wifiInterfaces) {
-             scanThread->interfaceName = QString::fromNSString(ifName);
-             scanThread->start();
-diff --git a/src/plugins/platforms/cocoa/qcocoascreen.mm b/src/plugins/platforms/cocoa/qcocoascreen.mm
-index afe14e623c..74d69c2fa1 100644
---- a/src/plugins/platforms/cocoa/qcocoascreen.mm
-+++ b/src/plugins/platforms/cocoa/qcocoascreen.mm
-@@ -127,7 +127,7 @@ void QCocoaScreen::updateProperties()
-     const qreal previousRefreshRate = m_refreshRate;
- 
-     // The reference screen for the geometry is always the primary screen
--    QRectF primaryScreenGeometry = QRectF::fromCGRect([[NSScreen screens] firstObject].frame);
-+    QRectF primaryScreenGeometry = QRectF::fromCGRect([[[NSScreen screens] firstObject] frame]);
-     m_geometry = qt_mac_flip(QRectF::fromCGRect(nsScreen.frame), primaryScreenGeometry).toRect();
-     m_availableGeometry = qt_mac_flip(QRectF::fromCGRect(nsScreen.visibleFrame), primaryScreenGeometry).toRect();
- 
-diff --git a/src/plugins/platforms/cocoa/qcocoawindow.mm b/src/plugins/platforms/cocoa/qcocoawindow.mm
-index df1ad82592..0318a4ff96 100644
---- a/src/plugins/platforms/cocoa/qcocoawindow.mm
-+++ b/src/plugins/platforms/cocoa/qcocoawindow.mm
-@@ -1704,7 +1704,7 @@ void QCocoaWindow::applyContentBorderThickness(NSWindow *window)
- 
-     if (!m_drawContentBorderGradient) {
-         window.styleMask = window.styleMask & ~NSWindowStyleMaskTexturedBackground;
--        [window.contentView.superview setNeedsDisplay:YES];
-+        [[window.contentView superview] setNeedsDisplay:YES];
-         window.titlebarAppearsTransparent = NO;
-         return;
-     }
-diff --git a/src/plugins/platforms/cocoa/qnswindow.mm b/src/plugins/platforms/cocoa/qnswindow.mm
-index c17ad47aba..a0f1dd38fb 100644
---- a/src/plugins/platforms/cocoa/qnswindow.mm
-+++ b/src/plugins/platforms/cocoa/qnswindow.mm
-@@ -230,7 +230,7 @@ static bool isMouseEvent(NSEvent *ev)
-     if (pw->frameStrutEventsEnabled() && isMouseEvent(theEvent)) {
-         NSPoint loc = [theEvent locationInWindow];
-         NSRect windowFrame = [self convertRectFromScreen:self.frame];
--        NSRect contentFrame = self.contentView.frame;
-+        NSRect contentFrame = [self.contentView frame];
-         if (NSMouseInRect(loc, windowFrame, NO) && !NSMouseInRect(loc, contentFrame, NO))
-             [qnsview_cast(pw->view()) handleFrameStrutMouseEvent:theEvent];
-     }
-@@ -257,7 +257,7 @@ static bool isMouseEvent(NSEvent *ev)
- + (void)applicationActivationChanged:(NSNotification*)notification
- {
-     const id sender = self;
--    NSEnumerator<NSWindow*> *windowEnumerator = nullptr;
-+    NSEnumerator *windowEnumerator = nullptr;
-     NSApplication *application = [NSApplication sharedApplication];
- 
-     // Unfortunately there's no NSWindowListOrderedBackToFront,
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-revert-no-macos10.10.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-revert-no-macos10.10.patch
deleted file mode 100644
index 29776518379d..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.12/qtbase-revert-no-macos10.10.patch
+++ /dev/null
@@ -1,102 +0,0 @@
-Revert "Remove code paths for macOS < 10.11"
-
-This reverts commit 138a65e0cfa80b13fd018a01e7d8b33341a3cfd3.
-
-From 138a65e0cfa80b13fd018a01e7d8b33341a3cfd3 Mon Sep 17 00:00:00 2001
-From: Jake Petroules <jake.petroules@qt.io>
-Date: Thu, 8 Feb 2018 11:05:42 -0800
-Subject: [PATCH] Remove code paths for macOS < 10.11
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Change-Id: I5ae02d88aa3dcd97d1f2ebf6255a68643e5d6daa
-Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
-Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
-Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
----
- .../fontdatabases/mac/qfontengine_coretext.mm            | 16 +++-------------
- src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm    |  6 +-----
- src/plugins/platforms/cocoa/qnswindowdelegate.mm         | 16 ----------------
- 3 files changed, 4 insertions(+), 34 deletions(-)
-
-diff --git a/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm b/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
-index 98b753eff9..489d9cd031 100644
---- a/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
-+++ b/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
-@@ -47,18 +47,28 @@
- 
- #include <cmath>
- 
--#if defined(Q_OS_MACOS)
-+#if defined(Q_OS_OSX) && !QT_OSX_DEPLOYMENT_TARGET_BELOW(__MAC_10_11)
- #import <AppKit/AppKit.h>
- #endif
- 
--#if defined(QT_PLATFORM_UIKIT)
-+#if defined(QT_PLATFORM_UIKIT) && !QT_IOS_DEPLOYMENT_TARGET_BELOW(__IPHONE_8_2)
- #import <UIKit/UIKit.h>
- #endif
- 
- // These are available cross platform, exported as kCTFontWeightXXX from CoreText.framework,
- // but they are not documented and are not in public headers so are private API and exposed
- // only through the NSFontWeightXXX and UIFontWeightXXX aliases in AppKit and UIKit (rdar://26109857)
--#if defined(Q_OS_MACOS)
-+#if QT_MAC_DEPLOYMENT_TARGET_BELOW(__MAC_10_11, __IPHONE_8_2)
-+#define kCTFontWeightUltraLight -0.8
-+#define kCTFontWeightThin -0.6
-+#define kCTFontWeightLight -0.4
-+#define kCTFontWeightRegular 0
-+#define kCTFontWeightMedium 0.23
-+#define kCTFontWeightSemibold 0.3
-+#define kCTFontWeightBold 0.4
-+#define kCTFontWeightHeavy 0.56
-+#define kCTFontWeightBlack 0.62
-+#elif defined(Q_OS_OSX)
- #define kCTFontWeightUltraLight NSFontWeightUltraLight
- #define kCTFontWeightThin NSFontWeightThin
- #define kCTFontWeightLight NSFontWeightLight
-diff --git a/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm b/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
-index 94f2125bad..272cd9f3dc 100644
---- a/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
-+++ b/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
-@@ -162,7 +162,11 @@ QT_NAMESPACE_ALIAS_OBJC_CLASS(QNSOpenSavePanelDelegate);
-     // resetting our mCurrentDir, set the delegate
-     // here to make sure it gets the correct value.
-     [mSavePanel setDelegate:self];
--    mOpenPanel.accessoryViewDisclosed = YES;
-+
-+#if QT_OSX_PLATFORM_SDK_EQUAL_OR_ABOVE(__MAC_10_11)
-+    if (__builtin_available(macOS 10.11, *))
-+        mOpenPanel.accessoryViewDisclosed = YES;
-+#endif
- 
-     if (mOptions->isLabelExplicitlySet(QFileDialogOptions::Accept))
-         [mSavePanel setPrompt:[self strip:options->labelText(QFileDialogOptions::Accept)]];
-diff --git a/src/plugins/platforms/cocoa/qnswindowdelegate.mm b/src/plugins/platforms/cocoa/qnswindowdelegate.mm
-index 057a4c2943..eb55e50622 100644
---- a/src/plugins/platforms/cocoa/qnswindowdelegate.mm
-+++ b/src/plugins/platforms/cocoa/qnswindowdelegate.mm
-@@ -103,6 +103,22 @@ static QRegExp whitespaceRegex = QRegExp(QStringLiteral("\\s*"));
-     return QCocoaScreen::mapToNative(maximizedFrame);
- }
- 
-+#if QT_MACOS_DEPLOYMENT_TARGET_BELOW(__MAC_10_11)
-+/*
-+    AppKit on OS X 10.10 wrongly calls windowWillUseStandardFrame:defaultFrame
-+    from -[NSWindow _frameForFullScreenMode] when going into fullscreen, resulting
-+    in black bars on top and bottom of the window. By implementing the following
-+    method, AppKit will choose that instead, and resolve the right fullscreen
-+    geometry.
-+*/
-+- (NSSize)window:(NSWindow *)window willUseFullScreenContentSize:(NSSize)proposedSize
-+{
-+    Q_UNUSED(proposedSize);
-+    Q_ASSERT(window == m_cocoaWindow->nativeWindow());
-+    return NSSizeFromCGSize(m_cocoaWindow->screen()->geometry().size().toCGSize());
-+}
-+#endif
-+
- - (BOOL)window:(NSWindow *)window shouldPopUpDocumentPathMenu:(NSMenu *)menu
- {
-     Q_UNUSED(window);
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.9/default.nix b/nixpkgs/pkgs/development/libraries/qt-5/5.9/default.nix
index be84691e6c33..d1e9af299261 100644
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.9/default.nix
+++ b/nixpkgs/pkgs/development/libraries/qt-5/5.9/default.nix
@@ -38,7 +38,7 @@ let
   srcs = import ./srcs.nix { inherit fetchurl; inherit mirror; };
 
   patches = {
-    qtbase = [ ./qtbase.patch ./qtbase-fixguicmake.patch ] ++ optional stdenv.isDarwin ./qtbase-darwin.patch;
+    qtbase = [ ./qtbase.patch ./qtbase-fixguicmake.patch ];
     qtdeclarative = [ ./qtdeclarative.patch ];
     qtscript = [ ./qtscript.patch ];
     qtserialport = [ ./qtserialport.patch ];
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/5.9/qtbase-darwin.patch b/nixpkgs/pkgs/development/libraries/qt-5/5.9/qtbase-darwin.patch
deleted file mode 100644
index 875fba12e2fb..000000000000
--- a/nixpkgs/pkgs/development/libraries/qt-5/5.9/qtbase-darwin.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-diff --git a/src/plugins/bearer/corewlan/qcorewlanengine.mm b/src/plugins/bearer/corewlan/qcorewlanengine.mm
-index 341d3bc..3368234 100644
---- a/src/plugins/bearer/corewlan/qcorewlanengine.mm
-+++ b/src/plugins/bearer/corewlan/qcorewlanengine.mm
-@@ -287,7 +287,7 @@ void QScanThread::getUserConfigurations()
-     QMacAutoReleasePool pool;
-     userProfiles.clear();
- 
--    NSArray<NSString *> *wifiInterfaces = [CWWiFiClient interfaceNames];
-+    NSArray *wifiInterfaces = [CWWiFiClient interfaceNames];
-     for (NSString *ifName in wifiInterfaces) {
- 
-         CWInterface *wifiInterface = [[CWWiFiClient sharedWiFiClient] interfaceWithName:ifName];
-@@ -602,7 +602,7 @@ void QCoreWlanEngine::doRequestUpdate()
- 
-     QMacAutoReleasePool pool;
- 
--    NSArray<NSString *> *wifiInterfaces = [CWWiFiClient interfaceNames];
-+    NSArray *wifiInterfaces = [CWWiFiClient interfaceNames];
-     for (NSString *ifName in wifiInterfaces) {
-             scanThread->interfaceName = QString::fromNSString(ifName);
-             scanThread->start();
-diff --git a/src/plugins/platforms/cocoa/qcocoawindow.mm b/src/plugins/platforms/cocoa/qcocoawindow.mm
-index 5cd4beb..84919e6 100644
---- a/src/plugins/platforms/cocoa/qcocoawindow.mm
-+++ b/src/plugins/platforms/cocoa/qcocoawindow.mm
-@@ -320,7 +320,7 @@ static void qt_closePopups()
- + (void)applicationActivationChanged:(NSNotification*)notification
- {
-     const id sender = self;
--    NSEnumerator<NSWindow*> *windowEnumerator = nullptr;
-+    NSEnumerator *windowEnumerator = nullptr;
-     NSApplication *application = [NSApplication sharedApplication];
- 
- #if QT_MACOS_PLATFORM_SDK_EQUAL_OR_ABOVE(__MAC_10_12)
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/modules/qtbase.nix b/nixpkgs/pkgs/development/libraries/qt-5/modules/qtbase.nix
index 71d27c33a928..bd92d9bc27cc 100644
--- a/nixpkgs/pkgs/development/libraries/qt-5/modules/qtbase.nix
+++ b/nixpkgs/pkgs/development/libraries/qt-5/modules/qtbase.nix
@@ -2,7 +2,7 @@
   stdenv, lib,
   src, patches, version, qtCompatVersion,
 
-  coreutils, bison, flex, gdb, gperf, lndir, patchelf, perl, pkgconfig, python2,
+  coreutils, bison, flex, gdb, gperf, lndir, perl, pkgconfig, python2,
   which,
   # darwin support
   darwin, libiconv,
@@ -78,17 +78,15 @@ stdenv.mkDerivation {
       [ libinput ]
       ++ lib.optional withGtk3 gtk3
     )
-    ++ lib.optional stdenv.isDarwin
-      # Needed for OBJC_CLASS_$_NSDate symbols.
-      [ darwin.cf-private ]
+       # Needed for OBJC_CLASS_$_NSDate symbols.
+    ++ lib.optional stdenv.isDarwin darwin.cf-private
     ++ lib.optional developerBuild gdb
     ++ lib.optional (cups != null) cups
     ++ lib.optional (mysql != null) mysql.connector-c
     ++ lib.optional (postgresql != null) postgresql;
 
   nativeBuildInputs =
-    [ bison flex gperf lndir perl pkgconfig python2 which ]
-    ++ lib.optional (!stdenv.isDarwin) patchelf;
+    [ bison flex gperf lndir perl pkgconfig python2 which ];
 
   propagatedNativeBuildInputs = [ lndir ];
 
@@ -199,26 +197,11 @@ stdenv.mkDerivation {
       ''-DNIXPKGS_LIBXCURSOR="${libXcursor.out}/lib/libXcursor"''
     ]
 
-    ++ (
-      if stdenv.isDarwin
-      then
-        [
-          "-Wno-missing-sysroot"
-          "-D__MAC_OS_X_VERSION_MAX_ALLOWED=1090"
-          "-D__AVAILABILITY_INTERNAL__MAC_10_10=__attribute__((availability(macosx,introduced=10.10)))"
-          # Note that nixpkgs's objc4 is from macOS 10.11 while the SDK is
-          # 10.9 which necessitates the above macro definition that mentions
-          # 10.10
-        ]
-      else
-        lib.optional libGLSupported ''-DNIXPKGS_MESA_GL="${libGL.out}/lib/libGL"''
-        ++ lib.optionals withGtk3
-          [
-            ''-DNIXPKGS_QGTK3_XDG_DATA_DIRS="${gtk3}/share/gsettings-schemas/${gtk3.name}"''
-            ''-DNIXPKGS_QGTK3_GIO_EXTRA_MODULES="${dconf.lib}/lib/gio/modules"''
-          ]
-    )
-
+    ++ lib.optional libGLSupported ''-DNIXPKGS_MESA_GL="${libGL.out}/lib/libGL"''
+    ++ lib.optionals withGtk3 [
+         ''-DNIXPKGS_QGTK3_XDG_DATA_DIRS="${gtk3}/share/gsettings-schemas/${gtk3.name}"''
+         ''-DNIXPKGS_QGTK3_GIO_EXTRA_MODULES="${dconf.lib}/lib/gio/modules"''
+       ]
     ++ lib.optional decryptSslTraffic "-DQT_DECRYPT_SSL_TRAFFIC";
 
   prefixKey = "-prefix ";
@@ -395,6 +378,7 @@ stdenv.mkDerivation {
     license = with licenses; [ fdl13 gpl2 lgpl21 lgpl3 ];
     maintainers = with maintainers; [ qknight ttuegel periklis bkchr ];
     platforms = platforms.unix;
+    broken = stdenv.isDarwin && (compareVersion "5.9.0" < 0);
   };
 
 }
diff --git a/nixpkgs/pkgs/development/libraries/qt-5/modules/qtwebengine.nix b/nixpkgs/pkgs/development/libraries/qt-5/modules/qtwebengine.nix
index af5804018874..86897cb3f16f 100644
--- a/nixpkgs/pkgs/development/libraries/qt-5/modules/qtwebengine.nix
+++ b/nixpkgs/pkgs/development/libraries/qt-5/modules/qtwebengine.nix
@@ -79,7 +79,7 @@ qtModule {
     cat <<EOF > src/3rdparty/chromium/build/mac/find_sdk.py
 #!/usr/bin/env python
 print("${darwin.apple_sdk.sdk}")
-print("10.10.0")
+print("10.12.0")
 EOF
 
     cat <<EOF > src/3rdparty/chromium/build/config/mac/sdk_info.py
diff --git a/nixpkgs/pkgs/development/libraries/range-v3/default.nix b/nixpkgs/pkgs/development/libraries/range-v3/default.nix
index 7fe4b504a992..256b756ed45d 100644
--- a/nixpkgs/pkgs/development/libraries/range-v3/default.nix
+++ b/nixpkgs/pkgs/development/libraries/range-v3/default.nix
@@ -2,13 +2,13 @@
 
 stdenv.mkDerivation rec {
   name = "range-v3-${version}";
-  version = "0.4.0";
+  version = "0.5.0";
 
   src = fetchFromGitHub {
     owner = "ericniebler";
     repo = "range-v3";
     rev = version;
-    sha256 = "1s5gj799aa94nfg3r24whq7ck69g0zypf70w14wx64pgwg0424vf";
+    sha256 = "0fzbpaa4vwlivi417zxm1d6v4lkp5c9f5bd706nn2fmw3zxjj815";
   };
 
   nativeBuildInputs = [ cmake ];
diff --git a/nixpkgs/pkgs/development/libraries/science/math/fenics/default.nix b/nixpkgs/pkgs/development/libraries/science/math/fenics/default.nix
index 6c939d9a3a43..8134cc63eb02 100644
--- a/nixpkgs/pkgs/development/libraries/science/math/fenics/default.nix
+++ b/nixpkgs/pkgs/development/libraries/science/math/fenics/default.nix
@@ -35,10 +35,15 @@ let
       url = "https://bitbucket.org/fenics-project/dijitso/downloads/dijitso-${version}.tar.gz";
       sha256 = "0mw6mynjmg6yl3l2k33yra2x84s4r6mh44ylhk9znjfk74jra8zg";
     };
-    buildInputs = [ numpy pytest six ];
-    checkPhase = ''
+    buildInputs = [ numpy six ];
+    nativeBuildInputs = [ pytest ];
+    preCheck = ''
       export HOME=$PWD
+    '';
+    checkPhase = ''
+      runHook preCheck
       py.test test/
+      runHook postCheck
     '';
     meta = {
       description = "Distributed just-in-time shared library building";
diff --git a/nixpkgs/pkgs/development/libraries/science/math/openblas/default.nix b/nixpkgs/pkgs/development/libraries/science/math/openblas/default.nix
index 5d0f6794d176..489883e644c7 100644
--- a/nixpkgs/pkgs/development/libraries/science/math/openblas/default.nix
+++ b/nixpkgs/pkgs/development/libraries/science/math/openblas/default.nix
@@ -58,6 +58,7 @@ let
       BINARY = 64;
       TARGET = setTarget "ATHLON";
       DYNAMIC_ARCH = true;
+      NO_AVX512 = true;
       USE_OPENMP = true;
     };
   };
diff --git a/nixpkgs/pkgs/development/libraries/sqlite/analyzer.nix b/nixpkgs/pkgs/development/libraries/sqlite/analyzer.nix
index 5c42f729469b..f0390486b10e 100644
--- a/nixpkgs/pkgs/development/libraries/sqlite/analyzer.nix
+++ b/nixpkgs/pkgs/development/libraries/sqlite/analyzer.nix
@@ -6,11 +6,11 @@ in
 
 stdenv.mkDerivation rec {
   name = "sqlite-analyzer-${version}";
-  version = "3.27.2";
+  version = "3.28.0";
 
   src = assert version == sqlite.version; fetchurl {
     url = "https://sqlite.org/2019/sqlite-src-${archiveVersion version}.zip";
-    sha256 = "02nz1y22wyb8101d9y6wfdrvp855wvch67js12p5y3riya345g8m";
+    sha256 = "15v57b113bpgcshfsx5jw93szar3da94rr03i053xhl15la7jllh";
   };
 
   nativeBuildInputs = [ unzip ];
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   meta = with stdenv.lib; {
     description = "A tool that shows statistics about SQLite databases";
     downloadPage = http://sqlite.org/download.html;
-    homepage = http://www.sqlite.org;
+    homepage = https://www.sqlite.org;
     license = licenses.publicDomain;
     maintainers = with maintainers; [ pesterhazy ];
     platforms = platforms.unix;
diff --git a/nixpkgs/pkgs/development/libraries/sqlite/default.nix b/nixpkgs/pkgs/development/libraries/sqlite/default.nix
index bacba396c25b..ea1c38ea476b 100644
--- a/nixpkgs/pkgs/development/libraries/sqlite/default.nix
+++ b/nixpkgs/pkgs/development/libraries/sqlite/default.nix
@@ -10,12 +10,12 @@ in
 
 stdenv.mkDerivation rec {
   name = "sqlite-${version}";
-  version = "3.27.2";
+  version = "3.28.0";
 
   # NB! Make sure to update analyzer.nix src (in the same directory).
   src = fetchurl {
     url = "https://sqlite.org/2019/sqlite-autoconf-${archiveVersion version}.tar.gz";
-    sha256 = "0vpgwszs19pwks2b4dhqwa0n6q5sx6pn1s7rngyyrd98xa2rxhsh";
+    sha256 = "1hxpi45crbqp6lacl7z611lna02k956m9bsy2bjzrbb2y23546yn";
   };
 
   outputs = [ "bin" "dev" "out" ];
@@ -75,8 +75,8 @@ stdenv.mkDerivation rec {
 
   meta = {
     description = "A self-contained, serverless, zero-configuration, transactional SQL database engine";
-    downloadPage = http://sqlite.org/download.html;
-    homepage = http://www.sqlite.org/;
+    downloadPage = https://sqlite.org/download.html;
+    homepage = https://www.sqlite.org/;
     license = licenses.publicDomain;
     maintainers = with maintainers; [ eelco np ];
     platforms = platforms.unix ++ platforms.windows;
diff --git a/nixpkgs/pkgs/development/libraries/tbb/default.nix b/nixpkgs/pkgs/development/libraries/tbb/default.nix
index 615ac4fa690c..f95ae385ab63 100644
--- a/nixpkgs/pkgs/development/libraries/tbb/default.nix
+++ b/nixpkgs/pkgs/development/libraries/tbb/default.nix
@@ -2,13 +2,13 @@
 
 with stdenv.lib; stdenv.mkDerivation rec {
   name = "tbb-${version}";
-  version = "2019_U5";
+  version = "2019_U6";
 
   src = fetchFromGitHub {
     owner = "01org";
     repo = "tbb";
     rev = version;
-    sha256 = "0390da1iya2mvn3ribjb1f8yvzsqsf5b16wn6dqbjxcz0crmwlzk";
+    sha256 = "1zbf06l659vq6s5wp3ln96ycwcd42caffan5vilqvqyxqvjljyic";
   };
 
   makeFlags = concatStringsSep " " (
diff --git a/nixpkgs/pkgs/development/libraries/tk/8.6.nix b/nixpkgs/pkgs/development/libraries/tk/8.6.nix
index cd8d42faa914..5013db64bbae 100644
--- a/nixpkgs/pkgs/development/libraries/tk/8.6.nix
+++ b/nixpkgs/pkgs/development/libraries/tk/8.6.nix
@@ -3,8 +3,8 @@
 callPackage ./generic.nix (args // rec {
 
   src = fetchurl {
-    url = "mirror://sourceforge/tcl/tk${tcl.version}-src.tar.gz";
-    sha256 = "17diivcfcwdhp4v5zi6j9nkxncccjqkivhp363c4wx5lf4d3fb6n";
+    url = "mirror://sourceforge/tcl/tk${tcl.version}.1-src.tar.gz"; # TODO: remove '.1' for v8.6.10 or v8.7.x
+    sha256 = "1d7bfkxpacy33w5nahf73lkwxqpff44w1jplg7i2gmwgiaawvjwg";
   };
 
   patches = [ ./different-prefix-with-tcl.patch ] ++ stdenv.lib.optionals stdenv.isDarwin [ ./Fix-bad-install_name-for-libtk8.6.dylib.patch ];
diff --git a/nixpkgs/pkgs/development/libraries/tk/generic.nix b/nixpkgs/pkgs/development/libraries/tk/generic.nix
index d5eaff77c117..10b8bc7cd717 100644
--- a/nixpkgs/pkgs/development/libraries/tk/generic.nix
+++ b/nixpkgs/pkgs/development/libraries/tk/generic.nix
@@ -19,16 +19,19 @@ stdenv.mkDerivation {
   postInstall = ''
     ln -s $out/bin/wish* $out/bin/wish
     cp ../{unix,generic}/*.h $out/include
+    ln -s $out/lib/libtk${tcl.release}.so $out/lib/libtk.so
   '';
 
   configureFlags = [
+    "--enable-threads"
     "--with-tcl=${tcl}/lib"
-  ] ++ stdenv.lib.optional enableAqua "--enable-aqua";
+  ] ++ stdenv.lib.optional stdenv.is64bit "--enable-64bit"
+    ++ stdenv.lib.optional enableAqua "--enable-aqua";
 
   nativeBuildInputs = [ pkgconfig ];
 
-  propagatedBuildInputs = [ tcl libXft ];
-  buildInputs = lib.optional enableAqua (with darwin; with apple_sdk.frameworks; [
+  propagatedBuildInputs = [ tcl libXft ]
+    ++ lib.optional enableAqua (with darwin; with apple_sdk.frameworks; [
       Cocoa cf-private
     ]);
 
@@ -44,7 +47,7 @@ stdenv.mkDerivation {
 
   meta = with stdenv.lib; {
     description = "A widget toolkit that provides a library of basic elements for building a GUI in many different programming languages";
-    homepage = http://www.tcl.tk/;
+    homepage = https://www.tcl.tk/;
     license = licenses.tcltk;
     platforms = platforms.all;
     maintainers = with maintainers; [ lovek323 vrthra ];
diff --git a/nixpkgs/pkgs/development/libraries/v8/build-standalone-static-library.patch b/nixpkgs/pkgs/development/libraries/v8/build-standalone-static-library.patch
deleted file mode 100644
index 994c322429d1..000000000000
--- a/nixpkgs/pkgs/development/libraries/v8/build-standalone-static-library.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-diff --git a/build/standalone.gypi b/build/standalone.gypi
-index b6519c4..ef9e7c5 100644
---- a/build/standalone.gypi
-+++ b/build/standalone.gypi
-@@ -373,6 +373,9 @@
-       }],
-     ],
-     'target_conditions': [
-+      ['_type=="static_library"', {
-+        'standalone_static_library': 1,
-+      }],
-       ['v8_code == 0', {
-         'defines!': [
-           'DEBUG',
diff --git a/nixpkgs/pkgs/development/libraries/v8/disable-building-tests.patch b/nixpkgs/pkgs/development/libraries/v8/disable-building-tests.patch
deleted file mode 100644
index 1854a9b7e567..000000000000
--- a/nixpkgs/pkgs/development/libraries/v8/disable-building-tests.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-diff --git a/Makefile b/Makefile
-index 9761265..80169b2 100644
---- a/Makefile
-+++ b/Makefile
-@@ -248,8 +248,6 @@ NACL_ARCHES = nacl_ia32 nacl_x64
- GYPFILES = third_party/icu/icu.gypi third_party/icu/icu.gyp \
- 	   build/shim_headers.gypi build/features.gypi build/standalone.gypi \
- 	   build/toolchain.gypi build/all.gyp build/mac/asan.gyp \
--	   test/cctest/cctest.gyp \
--	   test/unittests/unittests.gyp tools/gyp/v8.gyp \
- 	   tools/parser-shell.gyp testing/gmock.gyp testing/gtest.gyp \
- 	   buildtools/third_party/libc++abi/libc++abi.gyp \
- 	   buildtools/third_party/libc++/libc++.gyp samples/samples.gyp \
-diff --git a/build/all.gyp b/build/all.gyp
-index 4aeb507..1ff2c7a 100644
---- a/build/all.gyp
-+++ b/build/all.gyp
-@@ -10,8 +10,6 @@
-       'dependencies': [
-         '../samples/samples.gyp:*',
-         '../src/d8.gyp:d8',
--        '../test/cctest/cctest.gyp:*',
--        '../test/unittests/unittests.gyp:*',
-       ],
-       'conditions': [
-         ['component!="shared_library"', {
-
diff --git a/nixpkgs/pkgs/development/libraries/v8/fPIC-for-static.patch b/nixpkgs/pkgs/development/libraries/v8/fPIC-for-static.patch
deleted file mode 100644
index 39564772af86..000000000000
--- a/nixpkgs/pkgs/development/libraries/v8/fPIC-for-static.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-diff --git a/build/standalone.gypi b/build/standalone.gypi
-index 7670e5b..230518c 100644
---- a/build/standalone.gypi
-+++ b/build/standalone.gypi
-@@ -205,7 +205,7 @@
-           [ 'visibility=="hidden" and v8_enable_backtrace==0', {
-             'cflags': [ '-fvisibility=hidden' ],
-           }],
--          [ 'component=="shared_library"', {
-+          [ 'component=="shared_library" or component=="static_library" and (v8_target_arch=="x64" or v8_target_arch=="arm64")', {
-             'cflags': [ '-fPIC', ],
-           }],
-         ],
diff --git a/nixpkgs/pkgs/development/libraries/wxwidgets/2.9/default.nix b/nixpkgs/pkgs/development/libraries/wxwidgets/2.9/default.nix
index 1938b15efbb2..18e0cebec859 100644
--- a/nixpkgs/pkgs/development/libraries/wxwidgets/2.9/default.nix
+++ b/nixpkgs/pkgs/development/libraries/wxwidgets/2.9/default.nix
@@ -74,12 +74,13 @@ stdenv.mkDerivation {
   };
 
   enableParallelBuilding = true;
-  
+
   meta = {
     platforms = with platforms; darwin ++ linux;
     license = licenses.wxWindows;
     homepage = https://www.wxwidgets.org/;
     description = "a C++ library that lets developers create applications for Windows, macOS, Linux and other platforms with a single code base";
     longDescription = "wxWidgets gives you a single, easy-to-use API for writing GUI applications on multiple platforms that still utilize the native platform's controls and utilities. Link with the appropriate library for your platform and compiler, and your application will adopt the look and feel appropriate to that platform. On top of great GUI functionality, wxWidgets gives you: online help, network programming, streams, clipboard and drag and drop, multithreading, image loading and saving in a variety of popular formats, database support, HTML viewing and printing, and much more.";
+    badPlatforms = [ "x86_64-darwin" ];
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/default.nix b/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/default.nix
index 948b261fe45e..a89f132b8322 100644
--- a/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/default.nix
+++ b/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/default.nix
@@ -89,5 +89,6 @@ stdenv.mkDerivation rec {
     homepage = https://www.wxwidgets.org/;
     description = "a C++ library that lets developers create applications for Windows, macOS, Linux and other platforms with a single code base";
     longDescription = "wxWidgets gives you a single, easy-to-use API for writing GUI applications on multiple platforms that still utilize the native platform's controls and utilities. Link with the appropriate library for your platform and compiler, and your application will adopt the look and feel appropriate to that platform. On top of great GUI functionality, wxWidgets gives you: online help, network programming, streams, clipboard and drag and drop, multithreading, image loading and saving in a variety of popular formats, database support, HTML viewing and printing, and much more.";
+    badPlatforms = [ "x86_64-darwin" ];
   };
 }
diff --git a/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/mac.nix b/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/mac.nix
index 040273e28b99..6e559cfb6a94 100644
--- a/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/mac.nix
+++ b/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/mac.nix
@@ -71,5 +71,6 @@ stdenv.mkDerivation rec {
     homepage = https://www.wxwidgets.org/;
     description = "a C++ library that lets developers create applications for Windows, macOS, Linux and other platforms with a single code base";
     longDescription = "wxWidgets gives you a single, easy-to-use API for writing GUI applications on multiple platforms that still utilize the native platform's controls and utilities. Link with the appropriate library for your platform and compiler, and your application will adopt the look and feel appropriate to that platform. On top of great GUI functionality, wxWidgets gives you: online help, network programming, streams, clipboard and drag and drop, multithreading, image loading and saving in a variety of popular formats, database support, HTML viewing and printing, and much more.";
+    broken = true;
   };
 }