From 8661e2c9b1a177fa1773ec5966d24e187961ef21 Mon Sep 17 00:00:00 2001 From: Logan McNaughton <848146+loganmc10@users.noreply.github.com> Date: Sat, 20 Sep 2025 08:37:55 +0200 Subject: [PATCH] always enable lto --- build.rs | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/build.rs b/build.rs index 7b24100..3748c6d 100644 --- a/build.rs +++ b/build.rs @@ -73,7 +73,6 @@ fn main() { let os = std::env::var("CARGO_CFG_TARGET_OS").unwrap(); let arch = std::env::var("CARGO_CFG_TARGET_ARCH").unwrap(); - let profile = std::env::var("PROFILE").unwrap(); let opt_flag = if arch == "x86_64" { "-march=x86-64-v3" } else if arch == "aarch64" { @@ -96,11 +95,10 @@ fn main() { .unwrap(); } - if profile == "release" { - volk_build.flag("-flto=thin"); - rdp_build.flag("-flto=thin"); - simd_build.flag("-flto=thin"); - } + volk_build.flag("-flto=thin"); + rdp_build.flag("-flto=thin"); + simd_build.flag("-flto=thin"); + volk_build.compile("volk"); rdp_build.compile("parallel-rdp");