From 71ab3109f28e1719119b55f2f8f5e264061a9605 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Sun, 25 Dec 2022 02:40:25 +0100 Subject: [PATCH] borgbackup: unbundle xxhash and use pkgconfig Borg can use the python pkgconfig package to discover library paths, we don't need to pass them explicitly. Removes libb2, because borg since version 1.2.0 uses hashlib.blake2b instead. --- pkgs/tools/backup/borgbackup/default.nix | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/pkgs/tools/backup/borgbackup/default.nix b/pkgs/tools/backup/borgbackup/default.nix index 50efe7c5b7ad..89642b33a726 100644 --- a/pkgs/tools/backup/borgbackup/default.nix +++ b/pkgs/tools/backup/borgbackup/default.nix @@ -7,6 +7,7 @@ , openssh , openssl , python3 +, xxHash , zstd , installShellFiles , nixosTests @@ -41,6 +42,7 @@ python3.pkgs.buildPythonApplication rec { nativeBuildInputs = with python3.pkgs; [ cython setuptools-scm + pkgconfig # docs sphinxHook @@ -55,6 +57,7 @@ python3.pkgs.buildPythonApplication rec { buildInputs = [ libb2 lz4 + xxHash zstd openssl ] ++ lib.optionals stdenv.isLinux [ @@ -67,13 +70,6 @@ python3.pkgs.buildPythonApplication rec { (if stdenv.isLinux then pyfuse3 else llfuse) ]; - preConfigure = '' - export BORG_OPENSSL_PREFIX="${openssl.dev}" - export BORG_LZ4_PREFIX="${lz4.dev}" - export BORG_LIBB2_PREFIX="${libb2}" - export BORG_LIBZSTD_PREFIX="${zstd.dev}" - ''; - makeWrapperArgs = [ ''--prefix PATH ':' "${openssh}/bin"'' ];