anbox, arc_unpacker: fix build after defaulting to gcc12

This commit is contained in:
Vladimír Čunát 2023-02-04 12:35:47 +01:00
parent ad1bdf4e77
commit 68b1727907
No known key found for this signature in database
GPG key ID: E747DF1F9575A3AA
2 changed files with 3 additions and 2 deletions

View file

@ -85,8 +85,8 @@ stdenv.mkDerivation rec {
systemd
];
NIX_CFLAGS_COMPILE = [
# Needed with GCC 12
# Flag needed by GCC 12 but unrecognized by GCC 9 (aarch64-linux default now)
NIX_CFLAGS_COMPILE = lib.optionals (with stdenv; cc.isGNU && lib.versionAtLeast cc.version "12") [
"-Wno-error=mismatched-new-delete"
];

View file

@ -18,6 +18,7 @@ stdenv.mkDerivation rec {
postPatch = ''
cp ${catch2}/include/catch2/catch.hpp tests/test_support/catch.h
sed '1i#include <limits>' -i src/dec/eagls/pak_archive_decoder.cc # gcc12
'';
checkPhase = ''