From 46dc335c821fc33703b836c439b96b1597bc307b Mon Sep 17 00:00:00 2001 From: Slava Barinov Date: Wed, 10 Apr 2019 17:02:38 +0300 Subject: Fix LTO build error 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 fb8290f8e23..cca9e82b72a 100644 --- a/packaging/mesa.spec +++ b/packaging/mesa.spec @@ -61,7 +61,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