From 89b375e901c84fd145145f541e9e32f47a80be4f Mon Sep 17 00:00:00 2001 From: Benjamin Gilbert Date: Fri, 17 Dec 2021 18:52:02 -0500 Subject: [PATCH] Disable LTO to fix armv7hl builds --- disable-lto.patch | 10 ++++++++++ rust-coreos-installer.spec | 6 +++++- 2 files changed, 15 insertions(+), 1 deletion(-) create mode 100644 disable-lto.patch diff --git a/disable-lto.patch b/disable-lto.patch new file mode 100644 index 0000000..74f025e --- /dev/null +++ b/disable-lto.patch @@ -0,0 +1,10 @@ +--- coreos-installer-0.12.0/Cargo.toml.old 2021-12-17 18:10:11.278872432 -0500 ++++ coreos-installer-0.12.0/Cargo.toml 2021-12-17 18:39:05.822741078 -0500 +@@ -38,7 +38,6 @@ + opt-level = 3 + + [profile.release] +-lto = true + debug = true + + [lib] diff --git a/rust-coreos-installer.spec b/rust-coreos-installer.spec index f87b98d..1ed581c 100644 --- a/rust-coreos-installer.spec +++ b/rust-coreos-installer.spec @@ -23,9 +23,12 @@ Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{ Source1: https://github.com/coreos/%{crate}/releases/download/v%{version}/%{crate}-%{version}-vendor.tar.gz Source2: https://github.com/coreos/coreos-installer-dracut/archive/%{dracutcommit}/coreos-installer-dracut-%{dracutshortcommit}.tar.gz +# LTO causes OOM on Fedora armv7hl builders with Rust 1.57.0 +Patch1: disable-lto.patch + # rust-serde_with doesn't include the default "macros" feature. Bundle # serde_with and its dependencies while we sort out this mess. -Patch1: bundle-serde_with.patch +Patch2: bundle-serde_with.patch BuildRequires: rust-ident_case+default-devel Provides: bundled(crate(darling)) = 0.13.0 Provides: bundled(crate(darling_core)) = 0.13.0 @@ -215,6 +218,7 @@ from the initramfs. * Fri Dec 17 2021 Benjamin Gilbert - 0.12.0-1 - New release - Temporarily bundle serde_with and its dependencies +- Disable LTO to fix armv7hl builds * Wed Dec 15 2021 Sohan Kunkerkar - 0.11.0-3 - Remove conditional around sourcing the vendor tarball