summary refs log tree commit diff
path: root/pkgs/development/libraries
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/libraries')
-rw-r--r--pkgs/development/libraries/dbus/default.nix9
-rw-r--r--pkgs/development/libraries/dbus/make-dbus-conf.nix26
-rw-r--r--pkgs/development/libraries/glib/default.nix4
-rw-r--r--pkgs/development/libraries/gnu-efi/default.nix21
-rw-r--r--pkgs/development/libraries/gstreamer/bad/default.nix6
-rw-r--r--pkgs/development/libraries/jansson/default.nix22
-rw-r--r--pkgs/development/libraries/json-c/default.nix13
-rw-r--r--pkgs/development/libraries/libffi/default.nix13
-rw-r--r--pkgs/development/libraries/libffi/libffi-powerpc64.patch23
-rw-r--r--pkgs/development/libraries/libqmi/default.nix4
-rw-r--r--pkgs/development/libraries/libusb1/default.nix4
-rw-r--r--pkgs/development/libraries/mapnik/default.nix13
-rw-r--r--pkgs/development/libraries/mesa/default.nix8
-rw-r--r--pkgs/development/libraries/nss/esr.nix4
-rw-r--r--pkgs/development/libraries/nss/generic.nix4
-rw-r--r--pkgs/development/libraries/nss/latest.nix4
-rw-r--r--pkgs/development/libraries/openldap/default.nix42
-rw-r--r--pkgs/development/libraries/pipewire/default.nix17
-rw-r--r--pkgs/development/libraries/portaudio/default.nix9
-rw-r--r--pkgs/development/libraries/thrift/default.nix56
-rw-r--r--pkgs/development/libraries/tracker/default.nix8
-rw-r--r--pkgs/development/libraries/unicorn/default.nix17
-rw-r--r--pkgs/development/libraries/xxHash/default.nix39
-rw-r--r--pkgs/development/libraries/zlib/comprehensive-crc-validation-for-wrong-implementations.patch51
-rw-r--r--pkgs/development/libraries/zlib/default.nix6
25 files changed, 317 insertions, 106 deletions
diff --git a/pkgs/development/libraries/dbus/default.nix b/pkgs/development/libraries/dbus/default.nix
index e7852949249..4e41384847d 100644
--- a/pkgs/development/libraries/dbus/default.nix
+++ b/pkgs/development/libraries/dbus/default.nix
@@ -37,6 +37,10 @@ stdenv.mkDerivation rec {
   ] ++ (lib.optional stdenv.isSunOS ./implement-getgrouplist.patch);
 
   postPatch = ''
+    # We need to generate the file ourselves.
+    # https://gitlab.freedesktop.org/dbus/dbus/-/merge_requests/317
+    rm doc/catalog.xml
+
     substituteInPlace bus/Makefile.am \
       --replace 'install-data-hook:' 'disabled:' \
       --replace '$(mkinstalldirs) $(DESTDIR)$(localstatedir)/run/dbus' ':'
@@ -98,6 +102,11 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
+  makeFlags = [
+    # Fix paths in XML catalog broken by mismatching build/install datadir.
+    "dtddir=${placeholder "out"}/share/xml/dbus-1"
+  ];
+
   installFlags = [
     "sysconfdir=${placeholder "out"}/etc"
     "datadir=${placeholder "out"}/share"
diff --git a/pkgs/development/libraries/dbus/make-dbus-conf.nix b/pkgs/development/libraries/dbus/make-dbus-conf.nix
index ce5c0b3b577..35b232b2a32 100644
--- a/pkgs/development/libraries/dbus/make-dbus-conf.nix
+++ b/pkgs/development/libraries/dbus/make-dbus-conf.nix
@@ -1,4 +1,8 @@
-{ runCommand, writeText, libxslt, dbus
+{ runCommand
+, writeText
+, libxslt
+, dbus
+, findXMLCatalogs
 , serviceDirectories ? []
 , suidHelper ? "/var/setuid-wrappers/dbus-daemon-launch-helper"
 , apparmor ? "disabled" # one of enabled, disabled, required
@@ -14,19 +18,15 @@ runCommand "dbus-1"
     inherit serviceDirectories suidHelper apparmor;
     preferLocalBuild = true;
     allowSubstitutes = false;
-    XML_CATALOG_FILES = writeText "dbus-catalog.xml" ''
-      <?xml version="1.0"?>
-      <!DOCTYPE catalog PUBLIC
-        "-//OASIS//DTD Entity Resolution XML Catalog V1.0//EN"
-        "http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd">
 
-      <catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog">
-        <rewriteSystem
-          systemIdStartString="http://www.freedesktop.org/standards/dbus/1.0/"
-          rewritePrefix="file://${dbus}/share/xml/dbus-1/"/>
-      </catalog>
-    '';
-    nativeBuildInputs = [ libxslt.bin ];
+    nativeBuildInputs = [
+      libxslt
+      findXMLCatalogs
+    ];
+
+    buildInputs = [
+      dbus
+    ];
   }
   ''
     mkdir -p $out
diff --git a/pkgs/development/libraries/glib/default.nix b/pkgs/development/libraries/glib/default.nix
index 2c02bac92d2..29a1f642089 100644
--- a/pkgs/development/libraries/glib/default.nix
+++ b/pkgs/development/libraries/glib/default.nix
@@ -45,11 +45,11 @@ in
 
 stdenv.mkDerivation rec {
   pname = "glib";
-  version = "2.72.1";
+  version = "2.72.2";
 
   src = fetchurl {
     url = "mirror://gnome/sources/glib/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
-    sha256 = "wH5XFHslTO+SzoCgN43AwCpDWOfeRwLp9AMGl4EJX+I=";
+    sha256 = "eNWZoTPbp/4gNt+o24+2Exq5ZCeD/JV4sHogmVJS0t4=";
   };
 
   patches = optionals stdenv.isDarwin [
diff --git a/pkgs/development/libraries/gnu-efi/default.nix b/pkgs/development/libraries/gnu-efi/default.nix
index ef8ef7648eb..f331a8f753b 100644
--- a/pkgs/development/libraries/gnu-efi/default.nix
+++ b/pkgs/development/libraries/gnu-efi/default.nix
@@ -1,24 +1,17 @@
-{ lib, stdenv, buildPackages, fetchurl, fetchpatch, pciutils }:
+{ lib, stdenv, buildPackages, fetchurl, pciutils
+, gitUpdater }:
 
 with lib;
 
 stdenv.mkDerivation rec {
   pname = "gnu-efi";
-  version = "3.0.11";
+  version = "3.0.14";
 
   src = fetchurl {
     url = "mirror://sourceforge/gnu-efi/${pname}-${version}.tar.bz2";
-    sha256 = "1ffnc4xbzfggs37ymrgfx76j56kk2644c081ivhr2bjkla9ag3gj";
+    sha256 = "tztkOg1Wl9HzltdDFEjoht2AVmh4lXjj4aKCd8lShDU=";
   };
 
-  patches = [
-    # Fix build on armv6l
-    (fetchpatch {
-      url = "https://sourceforge.net/p/gnu-efi/patches/_discuss/thread/25bb273a18/9c4d/attachment/0001-Fix-ARCH-on-armv6-and-other-32-bit-ARM-platforms.patch";
-      sha256 = "0pj03h20g2bbz6fr753bj1scry6919h57l1h86z3b6q7hqfj0b4r";
-    })
-  ];
-
   buildInputs = [ pciutils ];
 
   hardeningDisable = [ "stackprotector" ];
@@ -29,6 +22,12 @@ stdenv.mkDerivation rec {
     "CROSS_COMPILE=${stdenv.cc.targetPrefix}"
   ];
 
+  passthru.updateScript = gitUpdater {
+    inherit pname version;
+    # No nicer place to find latest release.
+    url = "https://git.code.sf.net/p/gnu-efi/code";
+  };
+
   meta = with lib; {
     description = "GNU EFI development toolchain";
     homepage = "https://sourceforge.net/projects/gnu-efi/";
diff --git a/pkgs/development/libraries/gstreamer/bad/default.nix b/pkgs/development/libraries/gstreamer/bad/default.nix
index 758c4b091cd..28bcbe9a74c 100644
--- a/pkgs/development/libraries/gstreamer/bad/default.nix
+++ b/pkgs/development/libraries/gstreamer/bad/default.nix
@@ -93,6 +93,7 @@
 , Foundation
 , MediaToolbox
 , enableGplPlugins ? true
+, bluezSupport ? stdenv.isLinux
 }:
 
 stdenv.mkDerivation rec {
@@ -181,8 +182,9 @@ stdenv.mkDerivation rec {
     mjpegtools
     faad2
     x265
-  ] ++ lib.optionals stdenv.isLinux [
+  ] ++ lib.optionals bluezSupport [
     bluez
+  ] ++ lib.optionals stdenv.isLinux [
     libva # vaapi requires libva -> libdrm -> libpciaccess, which is Linux-only in nixpkgs
     wayland
     wayland-protocols
@@ -264,12 +266,12 @@ stdenv.mkDerivation rec {
     "-Dgs=disabled" # depends on `google-cloud-cpp`
     "-Donnx=disabled" # depends on `libonnxruntime` not packaged in nixpkgs as of writing
     "-Dopenaptx=enabled" # since gstreamer-1.20.1 `libfreeaptx` is supported for circumventing the dubious license conflict with `libopenaptx`
+    "-Dbluez=${if bluezSupport then "enabled" else "disabled"}"
   ]
   ++ lib.optionals (!stdenv.isLinux) [
     "-Dva=disabled" # see comment on `libva` in `buildInputs`
   ]
   ++ lib.optionals stdenv.isDarwin [
-    "-Dbluez=disabled"
     "-Dchromaprint=disabled"
     "-Ddirectfb=disabled"
     "-Dflite=disabled"
diff --git a/pkgs/development/libraries/jansson/default.nix b/pkgs/development/libraries/jansson/default.nix
index 21a697f1e3a..aafbe839bd4 100644
--- a/pkgs/development/libraries/jansson/default.nix
+++ b/pkgs/development/libraries/jansson/default.nix
@@ -1,18 +1,28 @@
-{lib, stdenv, fetchurl}:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "jansson";
-  version = "2.13.1";
+  version = "2.14";
 
-  src = fetchurl {
-    url = "https://digip.org/jansson/releases/${pname}-${version}.tar.gz";
-    sha256 = "0ks7gbs0j8p4dmmi2sq129mxy5gfg0z6220i1jk020mi2zd7gwzl";
+  src = fetchFromGitHub {
+    owner = "akheron";
+    repo = "jansson";
+    rev = "v${version}";
+    sha256 = "sha256-FQgy2+g3AyRVJeniqPQj0KNeHgPdza2pmEIXqSyYry4=";
   };
 
+  nativeBuildInputs = [ cmake ];
+
+  # networkmanager relies on libjansson.so:
+  #   https://github.com/NixOS/nixpkgs/pull/176302#issuecomment-1150239453
+  cmakeFlags = [ "-DJANSSON_BUILD_SHARED_LIBS=ON" ];
+
   meta = with lib; {
-    homepage = "http://www.digip.org/jansson/";
+    homepage = "https://github.com/akheron/jansson";
     description = "C library for encoding, decoding and manipulating JSON data";
+    changelog = "https://github.com/akheron/jansson/raw/v${version}/CHANGES";
     license = licenses.mit;
     platforms = platforms.all;
+    maintainers = [ maintainers.marsam ];
   };
 }
diff --git a/pkgs/development/libraries/json-c/default.nix b/pkgs/development/libraries/json-c/default.nix
index 5a77ea789af..d6aac7161d4 100644
--- a/pkgs/development/libraries/json-c/default.nix
+++ b/pkgs/development/libraries/json-c/default.nix
@@ -2,11 +2,11 @@
 
 stdenv.mkDerivation rec {
   pname = "json-c";
-  version = "0.15";
+  version = "0.16";
 
   src = fetchurl {
     url    = "https://s3.amazonaws.com/json-c_releases/releases/${pname}-${version}.tar.gz";
-    sha256 = "1im484iz08j3gmzpw07v16brwq46pxxj65i996kkp2vivcfhmn5q";
+    sha256 = "sha256-jkWsj5bsd5Hq87t+5Q6cIQC7vIe40PHQMMW6igKI2Ws=";
   };
 
   outputs = [ "out" "dev" ];
@@ -15,16 +15,15 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "A JSON implementation in C";
-    homepage    = "https://github.com/json-c/json-c/wiki";
-    maintainers = with maintainers; [ lovek323 ];
-    platforms   = platforms.unix;
-    license = licenses.mit;
-
     longDescription = ''
       JSON-C implements a reference counting object model that allows you to
       easily construct JSON objects in C, output them as JSON formatted strings
       and parse JSON formatted strings back into the C representation of JSON
       objects.
     '';
+    homepage    = "https://github.com/json-c/json-c/wiki";
+    maintainers = with maintainers; [ lovek323 ];
+    platforms   = platforms.unix;
+    license = licenses.mit;
   };
 }
diff --git a/pkgs/development/libraries/libffi/default.nix b/pkgs/development/libraries/libffi/default.nix
index 7387a4a1f06..0971091d8a1 100644
--- a/pkgs/development/libraries/libffi/default.nix
+++ b/pkgs/development/libraries/libffi/default.nix
@@ -7,11 +7,6 @@
 , dejagnu
 }:
 
-# Note: this package is used for bootstrapping fetchurl, and thus
-# cannot use fetchpatch! All mutable patches (generated by GitHub or
-# cgit) that are needed here should be included directly in Nixpkgs as
-# files.
-
 stdenv.mkDerivation rec {
   pname = "libffi";
   version = "3.4.2";
@@ -21,7 +16,13 @@ stdenv.mkDerivation rec {
     sha256 = "081nx7wpzds168jbr59m34n6s3lyiq6r8zggvqxvlslsc4hvf3sl";
   };
 
-  patches = [];
+  # Note: this package is used for bootstrapping fetchurl, and thus
+  # cannot use fetchpatch! All mutable patches (generated by GitHub or
+  # cgit) that are needed here should be included directly in Nixpkgs as
+  # files.
+  patches = [
+    ./libffi-powerpc64.patch
+  ];
 
   strictDeps = true;
   outputs = [ "out" "dev" "man" "info" ];
diff --git a/pkgs/development/libraries/libffi/libffi-powerpc64.patch b/pkgs/development/libraries/libffi/libffi-powerpc64.patch
new file mode 100644
index 00000000000..5748ac08498
--- /dev/null
+++ b/pkgs/development/libraries/libffi/libffi-powerpc64.patch
@@ -0,0 +1,23 @@
+https://github.com/libffi/libffi/issues/668
+--- a/src/powerpc/linux64.S
++++ b/src/powerpc/linux64.S
+@@ -29,6 +29,8 @@
+ #include <fficonfig.h>
+ #include <ffi.h>
+ 
++	.machine altivec
++
+ #ifdef POWERPC64
+ 	.hidden	ffi_call_LINUX64
+ 	.globl	ffi_call_LINUX64
+--- a/src/powerpc/linux64_closure.S
++++ b/src/powerpc/linux64_closure.S
+@@ -30,6 +30,8 @@
+ 
+ 	.file	"linux64_closure.S"
+ 
++	.machine altivec
++
+ #ifdef POWERPC64
+ 	FFI_HIDDEN (ffi_closure_LINUX64)
+ 	.globl  ffi_closure_LINUX64
diff --git a/pkgs/development/libraries/libqmi/default.nix b/pkgs/development/libraries/libqmi/default.nix
index 0906d7b967c..fb2d4aa69c9 100644
--- a/pkgs/development/libraries/libqmi/default.nix
+++ b/pkgs/development/libraries/libqmi/default.nix
@@ -45,8 +45,8 @@ stdenv.mkDerivation rec {
 
   configureFlags = [
     "--with-udev-base-dir=${placeholder "out"}/lib/udev"
-    "--enable-gtk-doc"
-    "--enable-introspection"
+    "--enable-gtk-doc=${if (stdenv.buildPlatform == stdenv.hostPlatform) then "yes" else "no"}"
+    "--enable-introspection=${if (stdenv.buildPlatform == stdenv.hostPlatform) then "yes" else "no"}"
   ];
 
   enableParallelBuilding = true;
diff --git a/pkgs/development/libraries/libusb1/default.nix b/pkgs/development/libraries/libusb1/default.nix
index 24b147d142d..3b23402fe33 100644
--- a/pkgs/development/libraries/libusb1/default.nix
+++ b/pkgs/development/libraries/libusb1/default.nix
@@ -13,13 +13,13 @@
 
 stdenv.mkDerivation rec {
   pname = "libusb";
-  version = "1.0.25";
+  version = "1.0.26";
 
   src = fetchFromGitHub {
     owner = "libusb";
     repo = "libusb";
     rev = "v${version}";
-    sha256 = "141wygijjcgka0h31504cdlvih4l2j02j67pcbb2l527p7dbc5pn";
+    sha256 = "sha256-LEy45YiFbueCCi8d2hguujMsxBezaTUERHUpFsTKGZQ=";
   };
 
   outputs = [ "out" "dev" ];
diff --git a/pkgs/development/libraries/mapnik/default.nix b/pkgs/development/libraries/mapnik/default.nix
index 14eb3c047e2..13e34bebee6 100644
--- a/pkgs/development/libraries/mapnik/default.nix
+++ b/pkgs/development/libraries/mapnik/default.nix
@@ -1,12 +1,15 @@
 { lib, stdenv, fetchzip
 , boost, cairo, freetype, gdal, harfbuzz, icu, libjpeg, libpng, libtiff
 , libwebp, libxml2, proj, python3, python ? python3, sqlite, zlib
+, sconsPackages
 
 # supply a postgresql package to enable the PostGIS input plugin
 , postgresql ? null
 }:
 
-stdenv.mkDerivation rec {
+let
+  scons = sconsPackages.scons_3_0_1;
+in stdenv.mkDerivation rec {
   pname = "mapnik";
   version = "3.1.0";
 
@@ -16,10 +19,16 @@ stdenv.mkDerivation rec {
     sha256 = "sha256-qqPqN4vs3ZsqKgnx21yQhX8OzHca/0O+3mvQ/vnC5EY=";
   };
 
+  postPatch = ''
+    substituteInPlace configure \
+      --replace '$PYTHON scons/scons.py' ${scons}/bin/scons
+    rm -r scons
+  '';
+
   # a distinct dev output makes python-mapnik fail
   outputs = [ "out" ];
 
-  nativeBuildInputs = [ python3 ];
+  nativeBuildInputs = [ scons ];
 
   buildInputs = [
     boost cairo freetype gdal harfbuzz icu libjpeg libpng libtiff
diff --git a/pkgs/development/libraries/mesa/default.nix b/pkgs/development/libraries/mesa/default.nix
index 8954eae19b4..0e10135d3d3 100644
--- a/pkgs/development/libraries/mesa/default.nix
+++ b/pkgs/development/libraries/mesa/default.nix
@@ -34,7 +34,8 @@ with lib;
 let
   # Release calendar: https://www.mesa3d.org/release-calendar.html
   # Release frequency: https://www.mesa3d.org/releasing.html#schedule
-  version = "22.0.4";
+  # 22.1 on darwin won't build: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6519
+  version = if stdenv.isDarwin then "22.0.4" else "22.1.1";
   branch  = versions.major version;
 
 self = stdenv.mkDerivation {
@@ -48,7 +49,10 @@ self = stdenv.mkDerivation {
       "ftp://ftp.freedesktop.org/pub/mesa/${version}/mesa-${version}.tar.xz"
       "ftp://ftp.freedesktop.org/pub/mesa/older-versions/${branch}.x/${version}/mesa-${version}.tar.xz"
     ];
-    sha256 = "1m0y8wgy48hmcidsr7sbk5hcw3v0qr8359fd2x34fvl2z9c1z5y7";
+    sha256 = {
+      "22.1.1" = "1w8fpki67238l4yc92hsnsh4402py9zspirbmirxp577zxjhi526";
+      "22.0.4" = "1m0y8wgy48hmcidsr7sbk5hcw3v0qr8359fd2x34fvl2z9c1z5y7";
+    }.${version};
   };
 
   # TODO:
diff --git a/pkgs/development/libraries/nss/esr.nix b/pkgs/development/libraries/nss/esr.nix
index a958fa059d6..a789f0306d3 100644
--- a/pkgs/development/libraries/nss/esr.nix
+++ b/pkgs/development/libraries/nss/esr.nix
@@ -1,4 +1,4 @@
 import ./generic.nix {
-  version = "3.68.3";
-  sha256 = "sha256-5NDZsLVhfLM0gSZC7YAfjlH1mVyN2FwN78jMra/Lwzc=";
+  version = "3.68.4";
+  hash = "sha256-K5/T9aG0nzs7KdEgAmdPcEgRViV1b7R3KELsfDm+Fgs=";
 }
diff --git a/pkgs/development/libraries/nss/generic.nix b/pkgs/development/libraries/nss/generic.nix
index 3affffda082..9a3d7bdfe27 100644
--- a/pkgs/development/libraries/nss/generic.nix
+++ b/pkgs/development/libraries/nss/generic.nix
@@ -1,4 +1,4 @@
-{ version, sha256 }:
+{ version, hash }:
 { lib
 , stdenv
 , fetchurl
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   src = fetchurl {
     url = "mirror://mozilla/security/nss/releases/NSS_${underscoreVersion}_RTM/src/${pname}-${version}.tar.gz";
-    inherit sha256;
+    inherit hash;
   };
 
   depsBuildBuild = [ buildPackages.stdenv.cc ];
diff --git a/pkgs/development/libraries/nss/latest.nix b/pkgs/development/libraries/nss/latest.nix
index 622c9fca858..fa99543eb37 100644
--- a/pkgs/development/libraries/nss/latest.nix
+++ b/pkgs/development/libraries/nss/latest.nix
@@ -5,6 +5,6 @@
 #       Example: nix-shell ./maintainers/scripts/update.nix --argstr package cacert
 
 import ./generic.nix {
-  version = "3.78";
-  sha256 = "sha256-9FXzQeeHwRZzKOgKhPd7mlV9WVBm3aZIahh01y2miAA=";
+  version = "3.79";
+  hash = "sha256-698tapZhO2/nCtV56fmD4OlOARAXHPspmdtjPTOUpRQ=";
 }
diff --git a/pkgs/development/libraries/openldap/default.nix b/pkgs/development/libraries/openldap/default.nix
index c57aa560fc2..551a0827eee 100644
--- a/pkgs/development/libraries/openldap/default.nix
+++ b/pkgs/development/libraries/openldap/default.nix
@@ -1,6 +1,7 @@
 { lib
 , stdenv
 , fetchurl
+, fetchpatch
 
 # dependencies
 , cyrus_sasl
@@ -21,6 +22,39 @@ stdenv.mkDerivation rec {
     hash = "sha256-gdCTRSMutiSG7PWsrNLFbAxFtKbIwGZhLn9CGiOhz4c";
   };
 
+  patches = [
+    # ITS#9840 - ldif-filter: fix parallel build failure
+    (fetchpatch {
+      url = "https://github.com/openldap/openldap/commit/7d977f51e6dfa570a471d163b9e8255bdd3dc12f.patch";
+      hash = "sha256:1vid6pj2gmqywbghnd380x19ml241ldc1fyslb6br6q27zpgbdlp";
+    })
+    # ITS#9840 - libraries/Makefile.in: ignore the mkdir errors
+    (fetchpatch {
+      url = "https://github.com/openldap/openldap/commit/71f24015c312171c00ce94c9ff9b9c6664bdca8d.patch";
+      hash = "sha256:1a81vv6nkhgiadnj4g1wyzgzdp2zd151h0vkwvv9gzmqvhwcnc04";
+    })
+    # ITS#7165 back-mdb: check for stale readers on
+    (fetchpatch {
+      url = "https://github.com/openldap/openldap/commit/7e7f01c301db454e8c507999c77b55a1d97efc21.patch";
+      hash = "sha256:1fc2yck2gn3zlpfqjdn56ar206npi8cmb8yg5ny4lww0ygmyzdfz";
+    })
+    # ITS#9858 back-mdb: delay indexer task startup
+    (fetchpatch {
+      url = "https://github.com/openldap/openldap/commit/ac061c684cc79d64ab4089fe3020921a0064a307.patch";
+      hash = "sha256:01f0y50zlcj6n5mfkmb0di4p5vrlgn31zccx4a9k5m8vzxaqmw9d";
+    })
+    # ITS#9858 back-mdb: fix index reconfig
+    (fetchpatch {
+      url = "https://github.com/openldap/openldap/commit/c43c7a937cfb3a781f99b458b7ad71eb564a2bc2.patch";
+      hash = "sha256:02yh0c8cyx14iir5qhfam5shrg5d3115s2nv0pmqdj6najrqc5mm";
+    })
+    # ITS#9157: check for NULL ld
+    (fetchpatch {
+      url = "https://github.com/openldap/openldap/commit/6675535cd6ad01f9519ecd5d75061a74bdf095c7.patch";
+      hash = "sha256:0dali5ifcwba8400s065f0fizl9h44i0mzb06qgxhygff6yfrgif";
+    })
+  ];
+
   # TODO: separate "out" and "bin"
   outputs = [
     "out"
@@ -59,7 +93,7 @@ stdenv.mkDerivation rec {
     "ac_cv_func_memcmp_working=yes"
   ] ++ lib.optional stdenv.isFreeBSD "--with-pic";
 
-  makeFlags= [
+  makeFlags = [
     "CC=${stdenv.cc.targetPrefix}cc"
     "STRIP="  # Disable install stripping as it breaks cross-compiling. We strip binaries anyway in fixupPhase.
     "prefix=${placeholder "out"}"
@@ -81,7 +115,7 @@ stdenv.mkDerivation rec {
   ];
 
   postBuild = ''
-    for module in ${lib.concatStringsSep " " extraContribModules}; do
+    for module in $extraContribModules; do
       make $makeFlags CC=$CC -C contrib/slapd-modules/$module
     done
   '';
@@ -105,7 +139,7 @@ stdenv.mkDerivation rec {
   ];
 
   postInstall = ''
-    for module in ${lib.concatStringsSep " " extraContribModules}; do
+    for module in $extraContribModules; do
       make $installFlags install -C contrib/slapd-modules/$module
     done
     chmod +x "$out"/lib/*.{so,dylib}
@@ -116,6 +150,6 @@ stdenv.mkDerivation rec {
     description = "An open source implementation of the Lightweight Directory Access Protocol";
     license = licenses.openldap;
     maintainers = with maintainers; [ ajs124 das_j hexa ];
-    platforms   = platforms.unix;
+    platforms = platforms.unix;
   };
 }
diff --git a/pkgs/development/libraries/pipewire/default.nix b/pkgs/development/libraries/pipewire/default.nix
index 96d8c9c2052..8d28ef5ad74 100644
--- a/pkgs/development/libraries/pipewire/default.nix
+++ b/pkgs/development/libraries/pipewire/default.nix
@@ -6,7 +6,9 @@
 , python3
 , meson
 , ninja
+, eudev
 , systemd
+, enableSystemd ? true
 , pkg-config
 , docutils
 , doxygen
@@ -127,8 +129,8 @@ let
       vulkan-headers
       vulkan-loader
       webrtc-audio-processing
-      systemd
-    ] ++ lib.optionals gstreamerSupport [ gst_all_1.gst-plugins-base gst_all_1.gstreamer ]
+    ] ++ (if enableSystemd then [ systemd ] else [ eudev ])
+    ++ lib.optionals gstreamerSupport [ gst_all_1.gst-plugins-base gst_all_1.gstreamer ]
     ++ lib.optionals libcameraSupport [ libcamera libdrm ]
     ++ lib.optional ffmpegSupport ffmpeg
     ++ lib.optionals bluezSupport [ bluez libfreeaptx ldacbt sbc fdk_aac ]
@@ -153,7 +155,9 @@ let
       "-Dlibpulse=${mesonEnableFeature pulseTunnelSupport}"
       "-Davahi=${mesonEnableFeature zeroconfSupport}"
       "-Dgstreamer=${mesonEnableFeature gstreamerSupport}"
-      "-Dsystemd-system-service=enabled"
+      "-Dsystemd-system-service=${mesonEnableFeature enableSystemd}"
+      "-Dudev=${mesonEnableFeature (!enableSystemd)}"
+      "-Dudevrulesdir=${placeholder "out"}/lib/udev/rules.d"
       "-Dffmpeg=${mesonEnableFeature ffmpegSupport}"
       "-Dbluez5=${mesonEnableFeature bluezSupport}"
       "-Dbluez5-backend-hsp-native=${mesonEnableFeature nativeHspSupport}"
@@ -193,8 +197,11 @@ let
         cp ${buildPackages.pipewire}/nix-support/*.json "$out/nix-support"
       ''}
 
-      moveToOutput "share/systemd/user/pipewire-pulse.*" "$pulse"
-      moveToOutput "lib/systemd/user/pipewire-pulse.*" "$pulse"
+      ${lib.optionalString enableSystemd ''
+        moveToOutput "share/systemd/user/pipewire-pulse.*" "$pulse"
+        moveToOutput "lib/systemd/user/pipewire-pulse.*" "$pulse"
+      ''}
+
       moveToOutput "bin/pipewire-pulse" "$pulse"
 
       moveToOutput "bin/pw-jack" "$jack"
diff --git a/pkgs/development/libraries/portaudio/default.nix b/pkgs/development/libraries/portaudio/default.nix
index c1c76a90017..22ff1e450c1 100644
--- a/pkgs/development/libraries/portaudio/default.nix
+++ b/pkgs/development/libraries/portaudio/default.nix
@@ -3,6 +3,7 @@
 , fetchurl
 , alsa-lib
 , pkg-config
+, which
 , AudioUnit
 , AudioToolbox
 , CoreAudio
@@ -18,7 +19,8 @@ stdenv.mkDerivation rec {
     sha256 = "1vrdrd42jsnffh6rq8ap2c6fr4g9fcld89z649fs06bwqx1bzvs7";
   };
 
-  nativeBuildInputs = [ pkg-config ];
+  strictDeps = true;
+  nativeBuildInputs = [ pkg-config which ];
   buildInputs = lib.optional (!stdenv.isDarwin) alsa-lib;
 
   configureFlags = [ "--disable-mac-universal" "--enable-cxx" ];
@@ -34,6 +36,11 @@ stdenv.mkDerivation rec {
   #     https://github.com/PortAudio/portaudio/commit/28d2781d9216115543aa3f0a0ffb7b4ee0fac551.patch
   enableParallelBuilding = false;
 
+  postPatch = ''
+    # workaround for the configure script which expects an absolute path
+    export AR=$(which $AR)
+  '';
+
   # not sure why, but all the headers seem to be installed by the make install
   installPhase = ''
     make install
diff --git a/pkgs/development/libraries/thrift/default.nix b/pkgs/development/libraries/thrift/default.nix
index f85e56578bb..f54288b5a3f 100644
--- a/pkgs/development/libraries/thrift/default.nix
+++ b/pkgs/development/libraries/thrift/default.nix
@@ -1,5 +1,15 @@
-{ lib, stdenv, fetchurl, boost, zlib, libevent, openssl, python3, cmake, pkg-config
-, bison, flex
+{ lib
+, stdenv
+, fetchurl
+, boost
+, zlib
+, libevent
+, openssl
+, python3
+, cmake
+, pkg-config
+, bison
+, flex
 , static ? stdenv.hostPlatform.isStatic
 }:
 
@@ -12,15 +22,39 @@ stdenv.mkDerivation rec {
     sha256 = "sha256-9GC1wcow2JGP+V6j62KRs5Uc9RhVNWYIjz8r6JgfYgk=";
   };
 
-  # Workaround to make the python wrapper not drop this package:
+  # Workaround to make the Python wrapper not drop this package:
   # pythonFull.buildEnv.override { extraLibs = [ thrift ]; }
   pythonPath = [];
 
-  nativeBuildInputs = [ cmake pkg-config bison flex ];
-  buildInputs = [ boost zlib libevent openssl ]
-    ++ lib.optionals (!static) [ (python3.withPackages (ps: [ps.twisted])) ];
+  nativeBuildInputs = [
+    bison
+    cmake
+    flex
+    pkg-config
+  ];
+
+  buildInputs = [
+    boost
+    libevent
+    openssl
+    zlib
+  ] ++ lib.optionals (!static) [
+    (python3.withPackages (ps: [ps.twisted]))
+  ];
+
+  postPatch = ''
+    # Python 3.10 related failures:
+    # SystemError: PY_SSIZE_T_CLEAN macro must be defined for '#' formats
+    # AttributeError: module 'collections' has no attribute 'Hashable'
+    substituteInPlace test/py/RunClientServer.py \
+      --replace "'FastbinaryTest.py'," "" \
+      --replace "'TestEof.py'," "" \
+      --replace "'TestFrozen.py'," ""
+  '';
 
-  preConfigure = "export PY_PREFIX=$out";
+  preConfigure = ''
+    export PY_PREFIX=$out
+  '';
 
   patches = [
     # ToStringTest.cpp is failing from some reason due to locale issue, this
@@ -43,12 +77,12 @@ stdenv.mkDerivation rec {
   disabledTests = [
     "PythonTestSSLSocket"
   ] ++ lib.optionals stdenv.isDarwin [
-    # tests that hang up in the darwin sandbox
+    # Tests that hang up in the Darwin sandbox
     "SecurityTest"
     "SecurityFromBufferTest"
     "python_test"
 
-    # tests that fail in the darwin sandbox when trying to use network
+    # Tests that fail in the Darwin sandbox when trying to use network
     "UnitTests"
     "TInterruptTest"
     "TServerIntegrationTest"
@@ -62,6 +96,7 @@ stdenv.mkDerivation rec {
   ];
 
   doCheck = !static;
+
   checkPhase = ''
     runHook preCheck
 
@@ -69,6 +104,7 @@ stdenv.mkDerivation rec {
 
     runHook postCheck
   '';
+
   enableParallelChecking = false;
 
   meta = with lib; {
@@ -76,6 +112,6 @@ stdenv.mkDerivation rec {
     homepage = "https://thrift.apache.org/";
     license = licenses.asl20;
     platforms = platforms.linux ++ platforms.darwin;
-    maintainers = [ maintainers.bjornfor ];
+    maintainers = with maintainers; [ bjornfor ];
   };
 }
diff --git a/pkgs/development/libraries/tracker/default.nix b/pkgs/development/libraries/tracker/default.nix
index 5cb3dc73daa..8489655dcb6 100644
--- a/pkgs/development/libraries/tracker/default.nix
+++ b/pkgs/development/libraries/tracker/default.nix
@@ -29,13 +29,13 @@
 
 stdenv.mkDerivation rec {
   pname = "tracker";
-  version = "3.3.0";
+  version = "3.3.1";
 
   outputs = [ "out" "dev" "devdoc" ];
 
   src = fetchurl {
     url = "mirror://gnome/sources/${pname}/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
-    sha256 = "Bwb5b+f5XfQqzsgSwd57RZOg1kgyHKg1BqnXHiJBe9o=";
+    sha256 = "Wtb1vJd4Hr9V7NaUfNSuf/QZJRZYDRC9g4Dx3UcZbtI=";
   };
 
   nativeBuildInputs = [
@@ -79,11 +79,7 @@ stdenv.mkDerivation rec {
   doCheck = true;
 
   postPatch = ''
-    patchShebangs utils/g-ir-merge/g-ir-merge
     patchShebangs utils/data-generators/cc/generate
-    patchShebangs tests/functional-tests/test-runner.sh.in
-    patchShebangs tests/functional-tests/*.py
-    patchShebangs examples/python/endpoint.py
   '';
 
   preCheck = ''
diff --git a/pkgs/development/libraries/unicorn/default.nix b/pkgs/development/libraries/unicorn/default.nix
index 30ceba76163..e558bbbbb54 100644
--- a/pkgs/development/libraries/unicorn/default.nix
+++ b/pkgs/development/libraries/unicorn/default.nix
@@ -1,4 +1,5 @@
-{ lib, stdenv
+{ lib
+, stdenv
 , fetchFromGitHub
 , pkg-config
 , cmake
@@ -7,17 +8,23 @@
 
 stdenv.mkDerivation rec {
   pname = "unicorn";
-  version = "2.0.0-rc5";
+  version = "2.0.0-rc7";
 
   src = fetchFromGitHub {
     owner = "unicorn-engine";
     repo = pname;
     rev = version;
-    sha256 = "1q9k8swnq4qsi54zdfaap69z56w3yj4n4ggm9pscmmmr69nply5f";
+    hash = "sha256-qlxtFCJBmouPuUEu8RduZM+rbOr52sGjdb8ZRHWmJ/w=";
   };
 
-  nativeBuildInputs = [ pkg-config cmake ];
-  buildInputs = lib.optionals stdenv.isDarwin [ IOKit ];
+  nativeBuildInputs = [
+    cmake
+    pkg-config
+  ];
+
+  buildInputs = lib.optionals stdenv.isDarwin [
+    IOKit
+  ];
 
   meta = with lib; {
     description = "Lightweight multi-platform CPU emulator library";
diff --git a/pkgs/development/libraries/xxHash/default.nix b/pkgs/development/libraries/xxHash/default.nix
index f4fa0611281..336dd5b3257 100644
--- a/pkgs/development/libraries/xxHash/default.nix
+++ b/pkgs/development/libraries/xxHash/default.nix
@@ -1,4 +1,9 @@
-{ lib, stdenv, fetchFromGitHub }:
+{ lib
+, stdenv
+, fetchFromGitHub
+, cmake
+, fetchurl
+}:
 
 stdenv.mkDerivation rec {
   pname = "xxHash";
@@ -11,21 +16,27 @@ stdenv.mkDerivation rec {
     sha256 = "sha256-2WoYCO6QRHWrbGP2mK04/sLNTyQLOuL3urVktilAwMA=";
   };
 
-  # Upstream Makefile does not anticipate that user may not want to
-  # build .so library.
-  postPatch = lib.optionalString stdenv.hostPlatform.isStatic ''
-    sed -i 's/lib: libxxhash.a libxxhash/lib: libxxhash.a/' Makefile
-    sed -i '/LIBXXH) $(DESTDIR/ d' Makefile
-  '';
+  patches = [
+    # Merged in https://github.com/Cyan4973/xxHash/pull/649
+    # Should be present in next release
+    (fetchurl {
+      name = "cmakeinstallfix.patch";
+      url = "https://github.com/Cyan4973/xxHash/commit/636f966ecc713c84ddd3b7ccfde2bfb2cc7492a0.patch";
+      hash = "sha256-fj+5V5mDhFgWGvrG1E4fEekL4eh7as0ouVvY4wnIHjs=";
+    })
+  ];
 
-  outputs = [ "out" "dev" ];
 
-  makeFlags = [ "PREFIX=$(dev)" "EXEC_PREFIX=$(out)" ];
+  nativeBuildInputs = [
+    cmake
+  ];
 
-  # pkgs/build-support/setup-hooks/compress-man-pages.sh hook fails
-  # to compress symlinked manpages. Avoid compressing manpages until
-  # it's fixed.
-  dontGzipMan = true;
+  # Using unofficial CMake build script to install CMake module files.
+  cmakeDir = "../cmake_unofficial";
+
+  cmakeFlags = [
+    "-DBUILD_SHARED_LIBS=${if stdenv.hostPlatform.isStatic then "OFF" else "ON"}"
+  ];
 
   meta = with lib; {
     description = "Extremely fast hash algorithm";
@@ -39,6 +50,6 @@ stdenv.mkDerivation rec {
     homepage = "https://github.com/Cyan4973/xxHash";
     license = with licenses; [ bsd2 gpl2 ];
     maintainers = with maintainers; [ orivej ];
-    platforms = platforms.unix;
+    platforms = platforms.all;
   };
 }
diff --git a/pkgs/development/libraries/zlib/comprehensive-crc-validation-for-wrong-implementations.patch b/pkgs/development/libraries/zlib/comprehensive-crc-validation-for-wrong-implementations.patch
new file mode 100644
index 00000000000..85a6a7e3ab4
--- /dev/null
+++ b/pkgs/development/libraries/zlib/comprehensive-crc-validation-for-wrong-implementations.patch
@@ -0,0 +1,51 @@
+From ec3df00224d4b396e2ac6586ab5d25f673caa4c2 Mon Sep 17 00:00:00 2001
+From: Mark Adler <madler@alumni.caltech.edu>
+Date: Wed, 30 Mar 2022 11:14:53 -0700
+Subject: [PATCH] Correct incorrect inputs provided to the CRC functions.
+
+The previous releases of zlib were not sensitive to incorrect CRC
+inputs with bits set above the low 32. This commit restores that
+behavior, so that applications with such bugs will continue to
+operate as before.
+---
+ crc32.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/crc32.c b/crc32.c
+index a1bdce5c2..451887bc7 100644
+--- a/crc32.c
++++ b/crc32.c
+@@ -630,7 +630,7 @@ unsigned long ZEXPORT crc32_z(crc, buf, len)
+ #endif /* DYNAMIC_CRC_TABLE */
+ 
+     /* Pre-condition the CRC */
+-    crc ^= 0xffffffff;
++    crc = (~crc) & 0xffffffff;
+ 
+     /* Compute the CRC up to a word boundary. */
+     while (len && ((z_size_t)buf & 7) != 0) {
+@@ -749,7 +749,7 @@ unsigned long ZEXPORT crc32_z(crc, buf, len)
+ #endif /* DYNAMIC_CRC_TABLE */
+ 
+     /* Pre-condition the CRC */
+-    crc ^= 0xffffffff;
++    crc = (~crc) & 0xffffffff;
+ 
+ #ifdef W
+ 
+@@ -1077,7 +1077,7 @@ uLong ZEXPORT crc32_combine64(crc1, crc2, len2)
+ #ifdef DYNAMIC_CRC_TABLE
+     once(&made, make_crc_table);
+ #endif /* DYNAMIC_CRC_TABLE */
+-    return multmodp(x2nmodp(len2, 3), crc1) ^ crc2;
++    return multmodp(x2nmodp(len2, 3), crc1) ^ (crc2 & 0xffffffff);
+ }
+ 
+ /* ========================================================================= */
+@@ -1112,5 +1112,5 @@ uLong crc32_combine_op(crc1, crc2, op)
+     uLong crc2;
+     uLong op;
+ {
+-    return multmodp(op, crc1) ^ crc2;
++    return multmodp(op, crc1) ^ (crc2 & 0xffffffff);
+ }
diff --git a/pkgs/development/libraries/zlib/default.nix b/pkgs/development/libraries/zlib/default.nix
index 6681be3c34c..1527be44f7a 100644
--- a/pkgs/development/libraries/zlib/default.nix
+++ b/pkgs/development/libraries/zlib/default.nix
@@ -42,6 +42,12 @@ stdenv.mkDerivation (rec {
 
   patches = [
     ./fix-configure-issue-cross.patch
+    # Starting zlib 1.2.12, zlib is stricter to incorrect CRC inputs
+    # with bits set above the low 32.
+    # see https://github.com/madler/zlib/issues/618
+    # TODO: remove the patch if upstream releases https://github.com/madler/zlib/commit/ec3df00224d4b396e2ac6586ab5d25f673caa4c2
+    # see https://github.com/NixOS/nixpkgs/issues/170539 for history.
+    ./comprehensive-crc-validation-for-wrong-implementations.patch
   ];
 
   strictDeps = true;