From 6930b5bda8431f2cdb12fecdb26d9d12bec7c4cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Tue, 31 Jan 2023 12:07:39 +0100 Subject: [PATCH] lyx, rr, linuxPackgaes.systemtap: fixup build with gcc12 --- pkgs/applications/misc/lyx/default.nix | 6 ++++++ pkgs/development/tools/analysis/rr/default.nix | 1 + pkgs/development/tools/profiling/systemtap/default.nix | 1 + 3 files changed, 8 insertions(+) diff --git a/pkgs/applications/misc/lyx/default.nix b/pkgs/applications/misc/lyx/default.nix index d1a19eeccc5..921ae570bca 100644 --- a/pkgs/applications/misc/lyx/default.nix +++ b/pkgs/applications/misc/lyx/default.nix @@ -11,6 +11,12 @@ mkDerivation rec { sha256 = "sha256-xr7SYzQZiY4Bp8w1AxDX2TS/WRyrcln8JYGqTADq+ng="; }; + # Needed with GCC 12 + postPatch = '' + sed '1i#include ' -i src/lyxfind.cpp + sed '1i#include ' -i src/insets/InsetListings.cpp + ''; + # LaTeX is used from $PATH, as people often want to have it with extra pkgs nativeBuildInputs = [ pkg-config makeWrapper ]; buildInputs = [ diff --git a/pkgs/development/tools/analysis/rr/default.nix b/pkgs/development/tools/analysis/rr/default.nix index e9437d718cf..40a7909f34a 100644 --- a/pkgs/development/tools/analysis/rr/default.nix +++ b/pkgs/development/tools/analysis/rr/default.nix @@ -24,6 +24,7 @@ stdenv.mkDerivation rec { postPatch = '' substituteInPlace src/Command.cc --replace '_BSD_SOURCE' '_DEFAULT_SOURCE' sed '7i#include ' -i src/Scheduler.cc + sed '1i#include ' -i src/test-monitor/test-monitor.cc patchShebangs . ''; diff --git a/pkgs/development/tools/profiling/systemtap/default.nix b/pkgs/development/tools/profiling/systemtap/default.nix index cadf9b9eeb1..4f7c87d8246 100644 --- a/pkgs/development/tools/profiling/systemtap/default.nix +++ b/pkgs/development/tools/profiling/systemtap/default.nix @@ -19,6 +19,7 @@ let nativeBuildInputs = [ pkg-config cpio python3 python3.pkgs.setuptools ]; buildInputs = [ elfutils gettext ]; enableParallelBuilding = true; + NIX_CFLAGS_COMPILE = [ "-Wno-error=deprecated-declarations" ]; # Needed with GCC 12 }; ## a kernel build dir as expected by systemtap