[Tizen] Support asan build option accepted/tizen/unified/20240228.170352 accepted/tizen/unified/x/20240304.072455 accepted/tizen/unified/x/20240304.072727
authorSeoyeon Kim <seoyeon2.kim@samsung.com>
Tue, 27 Feb 2024 07:12:46 +0000 (16:12 +0900)
committerSeoyeon Kim <seoyeon2.kim@samsung.com>
Tue, 27 Feb 2024 07:12:49 +0000 (16:12 +0900)
This reverts commit cc5ab7d5d96e4a41a0132ba6a9788fceff026e16.

packaging/dali-extension.spec

index d6720c1..9bd4a69 100755 (executable)
@@ -58,6 +58,13 @@ BuildRequires:  pkgconfig(evas)
 BuildRequires:  pkgconfig(rive_tizen)
 %endif
 
+# For ASAN test
+%if "%{vd_asan}" == "1" || "%{asan}" == "1"
+BuildRequires: asan-force-options
+BuildRequires: asan-build-env
+BuildRequires: libasan
+%endif
+
 %description
 dali-extension
 
@@ -237,6 +244,12 @@ CFLAGS+=" -DOS_TIZEN_TV"
 CXXFLAGS+=" -DOS_TIZEN_TV"
 %endif
 
+%if "%{vd_asan}" == "1" || "%{asan}" == "1"
+CFLAGS+=" -fsanitize=address"
+CXXFLAGS+=" -fsanitize=address"
+LDFLAGS+=" -fsanitize=address"
+%endif
+
 libtoolize --force
 cd %{_builddir}/%{name}-%{version}/build/tizen
 autoreconf --install