diff options
author | Sergei Trofimovich <slyich@gmail.com> | 2021-09-22 09:06:35 +0100 |
---|---|---|
committer | Sergei Trofimovich <slyich@gmail.com> | 2021-09-22 09:15:09 +0100 |
commit | eb49b17a0f4c7df0dad04d761bc9af69a952cbb8 (patch) | |
tree | cc8a1c7801fd0ae615c1cdce3d2caea5833919f9 | |
parent | abc00fd6bd7d81af4b86a1f2dc88432326dc9021 (diff) |
upx: disable blanket -Werror (fix gcc-11 build)
On gcc-11 build fails as: ``` $ nix-build -E 'with import ./.{}; upx.override { stdenv = gcc11Stdenv; }' ... ./../src/lzma-sdk/C/7zip/Compress/LZMA/../../../Common/MyCom.h:159:32: error: this 'if' clause does not guard... [-Werror=misleading-indentation] 159 | STDMETHOD_(ULONG, Release)() { if (--__m_RefCount != 0) \ | ^~ ```
-rw-r--r-- | pkgs/tools/compression/upx/default.nix | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/pkgs/tools/compression/upx/default.nix b/pkgs/tools/compression/upx/default.nix index 10e02626c0178..aff00402ed97c 100644 --- a/pkgs/tools/compression/upx/default.nix +++ b/pkgs/tools/compression/upx/default.nix @@ -8,15 +8,19 @@ stdenv.mkDerivation rec { sha256 = "051pk5jk8fcfg5mpgzj43z5p4cn7jy5jbyshyn78dwjqr7slsxs7"; }; - CXXFLAGS = "-Wno-unused-command-line-argument"; - buildInputs = [ ucl zlib perl ]; preConfigure = '' export UPX_UCLDIR=${ucl} ''; - makeFlags = [ "-C" "src" "CHECK_WHITESPACE=true" ]; + makeFlags = [ + "-C" "src" + "CHECK_WHITESPACE=true" + + # Disable blanket -Werror. Triggers failues on minor gcc-11 warnings. + "CXXFLAGS_WERROR=" + ]; installPhase = '' mkdir -p $out/bin |