Change-Id: I0e9ebd5b9fb2c214f94f94d122a674a53c2a11c4
Signed-off-by: Dongkyun Son <dongkyun.s@samsung.com>
BuildRequires: gcc-c++
BuildRequires: glibc-devel-static
BuildRequires: libelf0-devel
-%if %{asan}
-BuildRequires: libelf0-noasan-static
-%endif
+%{?asan:BuildRequires: libelf0-noasan-static}
Summary: An ELF Prelinking Utility
License: GPL-2.0+
Group: System/Base
unset MALLOC_PERTURB_
LDFLAGS=
-%if %{asan}
+%{?asan:
/usr/bin/gcc-unforce-options
cp %{_libdir}/libelf-noasan.a ./libelf.a
ELF_DIR=`pwd`
LDFLAGS="-L$ELF_DIR"
-%endif
+}
CFLAGS="$RPM_OPT_FLAGS" LDFLAGS="$LDFLAGS" \
%configure --prefix=/usr --mandir=%{_mandir} || cat config.log