From a3c00da98305ca0239634383b8bb1991cbb105ca Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Wed, 2 Nov 2022 07:26:49 +0000 Subject: [PATCH] libcamera: disable blanket -Werror `-Werror` flag usually causes build failures due to minor changes in compiler versions. They might be useful for developers themselves but are rarely useful for distributions. For example right now `libcamera` fails to compile on `gcc-13` due to a `gcc` infelicity: https://gcc.gnu.org/PR107488 While this concrete instance is a compiler bug generally `-Werror` makes users' lives harder. Specific `-Werror=` are better way to prevent certain classes of bugs. The change removes planket `-Werror` with `-Dwerror=false` flag. --- pkgs/development/libraries/libcamera/default.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkgs/development/libraries/libcamera/default.nix b/pkgs/development/libraries/libcamera/default.nix index c26dd91a2181..ff7cd7a193e3 100644 --- a/pkgs/development/libraries/libcamera/default.nix +++ b/pkgs/development/libraries/libcamera/default.nix @@ -77,6 +77,9 @@ stdenv.mkDerivation rec { "-Dv4l2=true" "-Dqcam=disabled" "-Dlc-compliance=disabled" # tries unconditionally to download gtest when enabled + # Avoid blanket -Werror to evade build failures on less + # tested compilers. + "-Dwerror=false" ]; # Fixes error on a deprecated declaration