From a59d5e302874e2c3dc4e08693ae43635fd2f0157 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Sun, 11 Feb 2024 09:55:14 +0000 Subject: [PATCH] svaba: fix `gcc-13` build failure Without the change build fails on `master` as https://hydra.nixos.org/build/249164637: In file included from Histogram.cpp:1: Histogram.h:104:61: error: 'uint32_t' does not name a type 104 | Histogram(const int32_t& start, const int32_t& end, const uint32_t& width); | ^~~~~~~~ --- pkgs/applications/science/biology/svaba/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkgs/applications/science/biology/svaba/default.nix b/pkgs/applications/science/biology/svaba/default.nix index 441c7ed6dcc3..d36c4b668ec3 100644 --- a/pkgs/applications/science/biology/svaba/default.nix +++ b/pkgs/applications/science/biology/svaba/default.nix @@ -14,6 +14,13 @@ stdenv.mkDerivation rec { buildInputs = [ zlib bzip2 xz ]; + postPatch = '' + # Fix gcc-13 build failure due to missing includes + sed -e '1i #include ' -i \ + SeqLib/src/non_api/Histogram.h \ + src/svaba/Histogram.h + ''; + # Workaround build failure on -fno-common toolchains like upstream # gcc-10. Otherwise build fails as: # ld: ./libfml.a(rle.o):/build/source/SeqLib/fermi-lite/rle.h:33: multiple definition of