about summary refs log tree commit diff
path: root/nixpkgs/pkgs/applications/science/biology/octopus/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/applications/science/biology/octopus/default.nix')
-rw-r--r--nixpkgs/pkgs/applications/science/biology/octopus/default.nix15
1 files changed, 11 insertions, 4 deletions
diff --git a/nixpkgs/pkgs/applications/science/biology/octopus/default.nix b/nixpkgs/pkgs/applications/science/biology/octopus/default.nix
index 35898aae9f3e..0090ca82d6c3 100644
--- a/nixpkgs/pkgs/applications/science/biology/octopus/default.nix
+++ b/nixpkgs/pkgs/applications/science/biology/octopus/default.nix
@@ -19,10 +19,17 @@ stdenv.mkDerivation rec {
     sha256 = "sha256-VaUr63v7mzhh4VBghH7a7qrqOYwl6vucmmKzTi9yAjY=";
   }) ];
 
-  env.NIX_CFLAGS_COMPILE = toString [
-    # Needed with GCC 12
-    "-Wno-error=deprecated-declarations"
-  ];
+  postPatch = ''
+    # Disable -Werror to avoid build failure on fresh toolchains like
+    # gcc-13.
+    substituteInPlace lib/date/CMakeLists.txt --replace-fail ' -Werror ' ' '
+    substituteInPlace lib/ranger/CMakeLists.txt --replace-fail ' -Werror ' ' '
+    substituteInPlace lib/tandem/CMakeLists.txt --replace-fail ' -Werror ' ' '
+    substituteInPlace src/CMakeLists.txt --replace-fail ' -Werror ' ' '
+
+    # Fix gcc-13 build due to missing <cstdint> header.
+    sed -e '1i #include <cstdint>' -i src/core/tools/vargen/utils/assembler.hpp
+  '';
 
   postInstall = ''
     mkdir $out/bin