From 4e2b38d13754c27ebed6457df03a4f49be966e9f Mon Sep 17 00:00:00 2001 From: timds Date: Mon, 1 Mar 2021 17:05:51 +0100 Subject: [PATCH] wal-g: enable support for brotli compression Brotli support was always on until v0.2.10. It is enabled by default in the wal-g's 'official' releases and build instructions, so it makes sense to enable it in nixpkgs too. wal-g has a Makefile (not used by nixpkgs) which statically links to brotli v1.0.7 (a C library). Nixpkgs dynamically links to brotli v1.0.9. --- pkgs/tools/backup/wal-g/default.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/backup/wal-g/default.nix b/pkgs/tools/backup/wal-g/default.nix index f3c415f3cd0f..de7f678fde8a 100644 --- a/pkgs/tools/backup/wal-g/default.nix +++ b/pkgs/tools/backup/wal-g/default.nix @@ -17,7 +17,10 @@ buildGoModule rec { subPackages = [ "main/pg" ]; - buildFlagsArray = [ "-ldflags=-s -w -X github.com/wal-g/wal-g/cmd/pg.WalgVersion=${version} -X github.com/wal-g/wal-g/cmd/pg.GitRevision=${src.rev}" ]; + buildFlagsArray = [ + "-tags=brotli" + "-ldflags=-s -w -X github.com/wal-g/wal-g/cmd/pg.WalgVersion=${version} -X github.com/wal-g/wal-g/cmd/pg.GitRevision=${src.rev}" + ]; postInstall = '' mv $out/bin/pg $out/bin/wal-g