nixpkgs/pkgs/development/libraries/cppunit/default.nix
Sergei Trofimovich 86e8528f27 cppunit: 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 `cppunit` 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=<foo>` are better way to prevent
certain classes of bugs.

The change removes planket `-Werror` with `--disable-werror` flag.
2022-11-01 22:35:52 +00:00

23 lines
615 B
Nix

{lib, stdenv, fetchurl}:
stdenv.mkDerivation rec {
pname = "cppunit";
version = "1.15.1";
src = fetchurl {
url = "https://dev-www.libreoffice.org/src/${pname}-${version}.tar.gz";
sha256 = "19qpqzy66bq76wcyadmi3zahk5v1ll2kig1nvg96zx9padkcdic9";
};
# Avoid blanket -Werror to evade build failures on less
# tested compilers.
configureFlags = [ "--disable-werror" ];
meta = with lib; {
homepage = "https://freedesktop.org/wiki/Software/cppunit/";
description = "C++ unit testing framework";
license = licenses.lgpl21;
platforms = platforms.linux ++ platforms.darwin;
};
}