diff options
author | Ryan Burns <rtburns@protonmail.com> | 2021-11-05 23:32:42 -0700 |
---|---|---|
committer | Ryan Burns <rtburns@protonmail.com> | 2021-11-05 23:32:46 -0700 |
commit | c9d935da0b2e23001497869359d48197ea88ebb4 (patch) | |
tree | 0b1c542813b516af2922920d576914c870da5b26 /pkgs/tools/system | |
parent | 233f451841a0bfb0f22c3e36d2e6893a8e8e27a8 (diff) |
efivar: fix LTO build
The LTO failure was not entirely due to 22284b07.
Based on https://salsa.debian.org/efi-team/efivar/-/commit/90fa4b7c105fb33f896ea291fb79de1fd0046f89
Diffstat (limited to 'pkgs/tools/system')
-rw-r--r-- | pkgs/tools/system/efivar/default.nix | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/pkgs/tools/system/efivar/default.nix b/pkgs/tools/system/efivar/default.nix index c92b28e7f5ea..ed831c5ecf6d 100644 --- a/pkgs/tools/system/efivar/default.nix +++ b/pkgs/tools/system/efivar/default.nix @@ -39,9 +39,11 @@ stdenv.mkDerivation rec { sha256 = "1ajj11wwsvamfspq4naanvw08h63gr0g71q0dfbrrywrhc0jlmdw"; }) ]; - # We have no LTO here since commit 22284b07. With GCC 10 that triggers a warning. - postPatch = "sed '/^OPTIMIZE /s/-flto//' -i Make.defaults"; - NIX_CFLAGS_COMPILE = "-Wno-error=stringop-truncation"; + + NIX_CFLAGS_COMPILE = [ + "-Wno-error=stringop-truncation" + "-flto-partition=none" + ]; nativeBuildInputs = [ pkg-config ]; buildInputs = [ popt ]; |