From 149bc610e755c46e5a4b6f3780fa64340e385627 Mon Sep 17 00:00:00 2001 From: Slava Barinov Date: Wed, 10 Apr 2019 17:02:38 +0300 Subject: Fix LTO build error Change-Id: I3179cd9ffd34431748913c0f7d3742918327731d Signed-off-by: Slava Barinov --- packaging/mesa.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packaging/mesa.spec b/packaging/mesa.spec index 91790d1ff0f..84e107f5345 100644 --- a/packaging/mesa.spec +++ b/packaging/mesa.spec @@ -62,7 +62,10 @@ cp %{SOURCE1001} . cp %{SOURCE1002} . %build -%{?asan:/usr/bin/gcc-unforce-options} +%{?asan:%gcc-unforce-options} +export CFLAGS=$(echo $CFLAGS | sed -e '/-flto/s/as-needed/no-as-needed/') +export CXXFLAGS=$(echo $CXXFLAGS | sed -e '/-flto/s/as-needed/no-as-needed/') + ./autogen.sh --prefix=%{_prefix} \ --libdir=%{_libdir} \ --disable-glx \ -- cgit v1.2.3