diff --git a/pkgs/tools/networking/unbound/default.nix b/pkgs/tools/networking/unbound/default.nix index a1a908340003..9d5c73286b6f 100644 --- a/pkgs/tools/networking/unbound/default.nix +++ b/pkgs/tools/networking/unbound/default.nix @@ -47,24 +47,15 @@ , gnutls }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "unbound"; - version = "1.18.0"; + version = "1.19.0"; src = fetchurl { - url = "https://nlnetlabs.nl/downloads/unbound/unbound-${version}.tar.gz"; - hash = "sha256-PalUkKhc/2Qg8m+uC4Skn1ES3xvxt/w0+HJPAggstxI="; + url = "https://nlnetlabs.nl/downloads/unbound/unbound-${finalAttrs.version}.tar.gz"; + hash = "sha256-qXUyRohUxhwt5IykFw3oVP07yVyAQ7sM+w/iZgWWZiQ="; }; - patches = [ - # Backport: fix libunbound with nettle. - (fetchpatch { - url = "https://github.com/NLnetLabs/unbound/commit/654a7eab62cbd1844d483cc4a0f2cf2fbcbaf00a.patch"; - excludes = [ "doc/Changelog" ]; - hash = "sha256-n3FCeZESFrrn6Wcf28Hb8WZs1eMHWjbsf2WCFOXU3lI="; - }) - ]; - outputs = [ "out" "lib" "man" ]; # "dev" would only split ~20 kB nativeBuildInputs = [ makeWrapper pkg-config ] @@ -157,7 +148,7 @@ stdenv.mkDerivation rec { + ''substituteInPlace "$lib/lib/libunbound.la" '' + lib.concatMapStrings (pkg: lib.optionalString (pkg ? dev) " --replace '-L${pkg.dev}/lib' '-L${pkg.out}/lib' --replace '-R${pkg.dev}/lib' '-R${pkg.out}/lib'") - (builtins.filter (p: p != null) buildInputs); + (builtins.filter (p: p != null) finalAttrs.buildInputs); passthru.tests = { inherit gnutls; @@ -172,4 +163,4 @@ stdenv.mkDerivation rec { maintainers = with maintainers; [ ajs124 ]; platforms = platforms.unix; }; -} +})