From 23bf79e670b0eb58a4901c1a195871d831f24f8b Mon Sep 17 00:00:00 2001 From: Youngsun Suh Date: Tue, 11 Feb 2025 14:58:07 +0900 Subject: [PATCH] [Tizen] Support asan build option This reverts commit a2c298863405081592b4a125dde3e1209b8ad53f. Change-Id: I79029a246654656be5e86a8e9d66236710bbcc05 --- packaging/dali-csharp-binder.spec | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/packaging/dali-csharp-binder.spec b/packaging/dali-csharp-binder.spec index a24c9172..9885e911 100644 --- a/packaging/dali-csharp-binder.spec +++ b/packaging/dali-csharp-binder.spec @@ -61,6 +61,13 @@ BuildRequires: pkgconfig(watch_viewer_dali) BuildRequires: pkgconfig(watch-holder-base) BuildRequires: pkgconfig(ecore-wl2) +# For ASAN test +%if "%{vd_asan}" == "1" || "%{asan}" == "1" +BuildRequires: asan-force-options +BuildRequires: asan-build-env +BuildRequires: libasan +%endif + # for multiprofile Requires: %{name}-compat = %{version}-%{release} Recommends: %{name}-profile_common = %{version}-%{release} @@ -226,6 +233,12 @@ CXXFLAGS+=" -DOVER_TIZEN_VERSION_7" %endif +%if "%{vd_asan}" == "1" || "%{asan}" == "1" +CFLAGS+=" -fsanitize=address" +CXXFLAGS+=" -fsanitize=address" +LDFLAGS+=" -fsanitize=address" +%endif + %if 0%{?enable_debug} cmake_flags+=" -DCMAKE_BUILD_TYPE=Debug" %endif -- 2.34.1