[TCT][packaging/scripts/src/templates][NonACR][Implemented Address Sanitizer Build...
authorperforce <perforce@perforce.(none)>
Mon, 13 Jun 2016 11:22:46 +0000 (20:22 +0900)
committerperforce <perforce@perforce.(none)>
Mon, 13 Jun 2016 11:25:27 +0000 (20:25 +0900)
Change-Id: I5cc47f50aa99e0755c7351bc2a639b23cfc424e3
Signed-off-by: perforce <perforce@perforce.(none)>
444 files changed:
README_ASAN.txt [new file with mode: 0644]
packaging/ctc/native-audio-io-ctc.spec
packaging/ctc/native-camera-ctc.spec
packaging/ctc/native-connection-ctc.spec
packaging/ctc/native-device-ctc.spec
packaging/ctc/native-filesystem-permission-ctc.spec
packaging/ctc/native-image-util-ctc.spec
packaging/ctc/native-libstorage-ctc.spec
packaging/ctc/native-location-manager-ctc.spec
packaging/ctc/native-mediacodec-ctc.spec
packaging/ctc/native-opengl-ctc.spec
packaging/ctc/native-platform-permission-ctc.spec
packaging/ctc/native-player-ctc.spec
packaging/ctc/native-runtime-info-ctc.spec
packaging/ctc/native-sensor-ctc.spec
packaging/ctc/native-sound-manager-ctc.spec
packaging/ctc/native-system-info-ctc.spec
packaging/ctc/native-telephony-ctc.spec
packaging/ctc/native-video-util-ctc.spec
packaging/ctc/native-wifi-direct-ctc.spec
packaging/itc/native-accounts-svc-itc.spec
packaging/itc/native-app-manager-itc.spec
packaging/itc/native-appcore-agent-itc.spec
packaging/itc/native-appcore-watch-itc.spec
packaging/itc/native-appcore-widget-itc.spec
packaging/itc/native-application-itc.spec
packaging/itc/native-audio-io-itc.spec
packaging/itc/native-badge-itc.spec
packaging/itc/native-base-utils-itc.spec
packaging/itc/native-bluetooth-itc.spec
packaging/itc/native-bundle-itc.spec
packaging/itc/native-cairo-itc.spec
packaging/itc/native-calendar-service2-itc.spec
packaging/itc/native-camera-itc.spec
packaging/itc/native-capi-maps-service-itc.spec
packaging/itc/native-capi-media-streamer-itc.spec
packaging/itc/native-capi-media-tool-itc.spec
packaging/itc/native-capi-mediademuxer-itc.spec
packaging/itc/native-capi-mediamuxer-itc.spec
packaging/itc/native-capi-message-port-itc.spec
packaging/itc/native-capi-ui-inputmethod-manager-itc.spec
packaging/itc/native-connection-itc.spec
packaging/itc/native-contacts-service2-itc.spec
packaging/itc/native-context-itc.spec
packaging/itc/native-dali-adaptor-itc.spec
packaging/itc/native-dali-core-itc.spec
packaging/itc/native-dali-toolkit-itc.spec
packaging/itc/native-data-control-itc.spec
packaging/itc/native-device-itc.spec
packaging/itc/native-dlog-itc.spec
packaging/itc/native-efl-ext-itc.spec
packaging/itc/native-efl-util-itc.spec
packaging/itc/native-email-itc.spec
packaging/itc/native-eom-itc.spec
packaging/itc/native-fido-client-itc.spec
packaging/itc/native-geofence-manager-itc.spec
packaging/itc/native-image-util-itc.spec
packaging/itc/native-iotcon-itc.spec
packaging/itc/native-key-manager-itc.spec
packaging/itc/native-libfeedback-itc.spec
packaging/itc/native-libstorage-itc.spec
packaging/itc/native-location-manager-itc.spec
packaging/itc/native-media-content-itc.spec
packaging/itc/native-media-controller-itc.spec
packaging/itc/native-media-key-itc.spec
packaging/itc/native-media-vision-itc.spec
packaging/itc/native-mediacodec-itc.spec
packaging/itc/native-mediastreamrecorder-itc.spec
packaging/itc/native-messages-itc.spec
packaging/itc/native-metadata-editor-itc.spec
packaging/itc/native-metadata-extractor-itc.spec
packaging/itc/native-mime-type-itc.spec
packaging/itc/native-minicontrol-itc.spec
packaging/itc/native-motion-itc.spec
packaging/itc/native-mtp-itc.spec
packaging/itc/native-native-common-itc.spec
packaging/itc/native-nfc-itc.spec
packaging/itc/native-notification-itc.spec
packaging/itc/native-nsd-itc.spec
packaging/itc/native-oauth2-itc.spec
packaging/itc/native-package-manager-itc.spec
packaging/itc/native-phonenumber-utils-itc.spec
packaging/itc/native-player-itc.spec
packaging/itc/native-privilege-info-itc.spec
packaging/itc/native-push-itc.spec
packaging/itc/native-radio-itc.spec
packaging/itc/native-recorder-itc.spec
packaging/itc/native-runtime-info-itc.spec
packaging/itc/native-screen-mirroring-itc.spec
packaging/itc/native-sensor-itc.spec
packaging/itc/native-service-adaptor-itc.spec
packaging/itc/native-shortcut-itc.spec
packaging/itc/native-smartcard-itc.spec
packaging/itc/native-sound-manager-itc.spec
packaging/itc/native-stt-itc.spec
packaging/itc/native-sync-manager-itc.spec
packaging/itc/native-system-info-itc.spec
packaging/itc/native-system-settings-itc.spec
packaging/itc/native-tbm-itc.spec
packaging/itc/native-telephony-itc.spec
packaging/itc/native-thumbnail-util-itc.spec
packaging/itc/native-tone-player-itc.spec
packaging/itc/native-ttrace-itc.spec
packaging/itc/native-tts-itc.spec
packaging/itc/native-url-download-itc.spec
packaging/itc/native-video-util-itc.spec
packaging/itc/native-voice-control-elm-itc.spec
packaging/itc/native-voice-control-itc.spec
packaging/itc/native-vpn-service-itc.spec
packaging/itc/native-wav-player-itc.spec
packaging/itc/native-webkit2-itc.spec
packaging/itc/native-widget_service-itc.spec
packaging/itc/native-widget_viewer_evas-itc.spec
packaging/itc/native-wifi-direct-itc.spec
packaging/itc/native-wifi-itc.spec
packaging/utc/core-accounts-svc-tests.spec
packaging/utc/core-app-manager-tests.spec
packaging/utc/core-appcore-agent-tests.spec
packaging/utc/core-appcore-watch-tests.spec
packaging/utc/core-appcore-widget-tests.spec
packaging/utc/core-application-tests.spec
packaging/utc/core-attach-panel-tests.spec
packaging/utc/core-audio-io-tests.spec
packaging/utc/core-badge-tests.spec
packaging/utc/core-base-utils-tests.spec
packaging/utc/core-bluetooth-tests.spec
packaging/utc/core-bundle-tests.spec
packaging/utc/core-cairo-tests.spec
packaging/utc/core-calendar-service2-tests.spec
packaging/utc/core-camera-tests.spec
packaging/utc/core-capi-maps-service-tests.spec
packaging/utc/core-capi-media-streamer-tests.spec
packaging/utc/core-capi-media-vision-tests.spec
packaging/utc/core-capi-message-port-tests.spec
packaging/utc/core-capi-ui-inputmethod-manager-tests.spec
packaging/utc/core-capi-ui-inputmethod-tests.spec
packaging/utc/core-connection-tests.spec
packaging/utc/core-contacts-service2-tests.spec
packaging/utc/core-context-tests.spec
packaging/utc/core-d2d-conv-manager-tests.spec
packaging/utc/core-dali-adaptor-tests.spec
packaging/utc/core-dali-core-tests.spec
packaging/utc/core-dali-toolkit-tests.spec
packaging/utc/core-data-control-tests.spec
packaging/utc/core-device-tests.spec
packaging/utc/core-dlog-tests.spec
packaging/utc/core-efl-ext-tests.spec
packaging/utc/core-efl-util-tests.spec
packaging/utc/core-email-tests.spec
packaging/utc/core-eom-tests.spec
packaging/utc/core-fido-client-tests.spec
packaging/utc/core-geofence-manager-tests.spec
packaging/utc/core-http-tests.spec
packaging/utc/core-image-util-tests.spec
packaging/utc/core-iotcon-tests.spec
packaging/utc/core-key-manager-tests.spec
packaging/utc/core-libfeedback-tests.spec
packaging/utc/core-libstorage-tests.spec
packaging/utc/core-libstorage64-tests.spec
packaging/utc/core-location-manager-tests.spec
packaging/utc/core-media-content-tests.spec
packaging/utc/core-media-controller-tests.spec
packaging/utc/core-media-key-tests.spec
packaging/utc/core-mediacodec-tests.spec
packaging/utc/core-mediademuxer-tests.spec
packaging/utc/core-mediamuxer-tests.spec
packaging/utc/core-mediatool-tests.spec
packaging/utc/core-messages-tests.spec
packaging/utc/core-metadata-editor-tests.spec
packaging/utc/core-metadata-extractor-tests.spec
packaging/utc/core-mime-type-tests.spec
packaging/utc/core-minicontrol-tests.spec
packaging/utc/core-motion-tests.spec
packaging/utc/core-mtp-tests.spec
packaging/utc/core-native-common-tests.spec
packaging/utc/core-nfc-tests.spec
packaging/utc/core-notification-tests.spec
packaging/utc/core-nsd-tests.spec
packaging/utc/core-oauth2-tests.spec
packaging/utc/core-package-manager-tests.spec
packaging/utc/core-phonenumber-utils-tests.spec
packaging/utc/core-player-tests.spec
packaging/utc/core-privilege-info-tests.spec
packaging/utc/core-push-tests.spec
packaging/utc/core-radio-tests.spec
packaging/utc/core-recorder-tests.spec
packaging/utc/core-runtime-info-tests.spec
packaging/utc/core-screen-mirroring-tests.spec
packaging/utc/core-sensor-tests.spec
packaging/utc/core-service-adaptor-tests.spec
packaging/utc/core-shortcut-tests.spec
packaging/utc/core-smartcard-tests.spec
packaging/utc/core-sound-manager-tests.spec
packaging/utc/core-streamrecorder-tests.spec
packaging/utc/core-stt-tests.spec
packaging/utc/core-sync-manager-tests.spec
packaging/utc/core-system-info-tests.spec
packaging/utc/core-system-settings-tests.spec
packaging/utc/core-tbm-tests.spec
packaging/utc/core-telephony-tests.spec
packaging/utc/core-thumbnail-util-tests.spec
packaging/utc/core-tone-player-tests.spec
packaging/utc/core-trace-tests.spec
packaging/utc/core-tts-tests.spec
packaging/utc/core-url-download-tests.spec
packaging/utc/core-video-util-tests.spec
packaging/utc/core-voice-control-elm-tests.spec
packaging/utc/core-voice-control-tests.spec
packaging/utc/core-vpn-tests.spec
packaging/utc/core-wav-player-tests.spec
packaging/utc/core-webkit2-tests.spec
packaging/utc/core-widget_service-tests.spec
packaging/utc/core-widget_viewer_evas-tests.spec
packaging/utc/core-wifi-direct-tests.spec
packaging/utc/core-wifi-tests.spec
scripts/tcbuild.sh
scripts/tcbuildsdk.sh
src/CMakeLists.txt
src/common/tct_common.c
src/common/tct_common.h
src/ctc/audio-io/CMakeLists.txt
src/ctc/camera/CMakeLists.txt
src/ctc/connection/CMakeLists.txt
src/ctc/device/CMakeLists.txt
src/ctc/filesystem-permission/CMakeLists.txt
src/ctc/image-util/CMakeLists.txt
src/ctc/libstorage/CMakeLists.txt
src/ctc/location-manager/CMakeLists.txt
src/ctc/mediacodec/CMakeLists.txt
src/ctc/opengl/CMakeLists.txt
src/ctc/platform-permission/CMakeLists.txt
src/ctc/player/CMakeLists.txt
src/ctc/runtime-info/CMakeLists.txt
src/ctc/sensor/CMakeLists.txt
src/ctc/sound-manager/CMakeLists.txt
src/ctc/system-info/CMakeLists.txt
src/ctc/telephony/CMakeLists.txt
src/ctc/video-util/CMakeLists.txt
src/ctc/wifi-direct/CMakeLists.txt
src/itc/accounts-svc/CMakeLists.txt
src/itc/app-manager/CMakeLists.txt
src/itc/appcore-agent/CMakeLists.txt
src/itc/appcore-watch/CMakeLists.txt
src/itc/appcore-widget/CMakeLists.txt
src/itc/application/CMakeLists.txt
src/itc/audio-io/CMakeLists.txt
src/itc/badge/CMakeLists.txt
src/itc/base-utils/CMakeLists.txt
src/itc/bluetooth/CMakeLists.txt
src/itc/bundle/CMakeLists.txt
src/itc/cairo/CMakeLists.txt
src/itc/calendar-service2/CMakeLists.txt
src/itc/camera/CMakeLists.txt
src/itc/capi-maps-service/CMakeLists.txt
src/itc/capi-media-streamer/CMakeLists.txt
src/itc/capi-media-tool/CMakeLists.txt
src/itc/capi-mediademuxer/CMakeLists.txt
src/itc/capi-mediamuxer/CMakeLists.txt
src/itc/capi-message-port/CMakeLists.txt
src/itc/capi-ui-inputmethod-manager/CMakeLists.txt
src/itc/connection/CMakeLists.txt
src/itc/contacts-service2/CMakeLists.txt
src/itc/context/CMakeLists.txt
src/itc/dali-adaptor/CMakeLists.txt
src/itc/dali-core/CMakeLists.txt
src/itc/dali-toolkit/CMakeLists.txt
src/itc/data-control/CMakeLists.txt
src/itc/device/CMakeLists.txt
src/itc/dlog/CMakeLists.txt
src/itc/efl-ext/CMakeLists.txt
src/itc/efl-util/CMakeLists.txt
src/itc/email/CMakeLists.txt
src/itc/eom/CMakeLists.txt
src/itc/fido-client/CMakeLists.txt
src/itc/geofence-manager/CMakeLists.txt
src/itc/image-util/CMakeLists.txt
src/itc/iotcon/CMakeLists.txt
src/itc/key-manager/CMakeLists.txt
src/itc/libfeedback/CMakeLists.txt
src/itc/libstorage/CMakeLists.txt
src/itc/location-manager/CMakeLists.txt
src/itc/media-content/CMakeLists.txt
src/itc/media-controller/CMakeLists.txt
src/itc/media-key/CMakeLists.txt
src/itc/media-vision/CMakeLists.txt
src/itc/mediacodec/CMakeLists.txt
src/itc/mediastreamrecorder/CMakeLists.txt
src/itc/messages/CMakeLists.txt
src/itc/metadata-editor/CMakeLists.txt
src/itc/metadata-extractor/CMakeLists.txt
src/itc/mime-type/CMakeLists.txt
src/itc/minicontrol/CMakeLists.txt
src/itc/motion/CMakeLists.txt
src/itc/mtp/CMakeLists.txt
src/itc/native-common/CMakeLists.txt
src/itc/nfc/CMakeLists.txt
src/itc/notification/CMakeLists.txt
src/itc/nsd/CMakeLists.txt
src/itc/oauth2/CMakeLists.txt
src/itc/package-manager/CMakeLists.txt
src/itc/phonenumber-utils/CMakeLists.txt
src/itc/player/CMakeLists.txt
src/itc/privilege-info/CMakeLists.txt
src/itc/push/CMakeLists.txt
src/itc/radio/CMakeLists.txt
src/itc/recorder/CMakeLists.txt
src/itc/runtime-info/CMakeLists.txt
src/itc/screen-mirroring/CMakeLists.txt
src/itc/sensor/CMakeLists.txt
src/itc/service-adaptor/CMakeLists.txt
src/itc/shortcut/CMakeLists.txt
src/itc/smartcard/CMakeLists.txt
src/itc/sound-manager/CMakeLists.txt
src/itc/stt/CMakeLists.txt
src/itc/sync-manager/CMakeLists.txt
src/itc/system-info/CMakeLists.txt
src/itc/system-settings/CMakeLists.txt
src/itc/tbm/CMakeLists.txt
src/itc/telephony/CMakeLists.txt
src/itc/thumbnail-util/CMakeLists.txt
src/itc/tone-player/CMakeLists.txt
src/itc/ttrace/CMakeLists.txt
src/itc/tts/CMakeLists.txt
src/itc/url-download/CMakeLists.txt
src/itc/video-util/CMakeLists.txt
src/itc/voice-control-elm/CMakeLists.txt
src/itc/voice-control/CMakeLists.txt
src/itc/vpn-service/CMakeLists.txt
src/itc/wav-player/CMakeLists.txt
src/itc/webkit2/CMakeLists.txt
src/itc/widget_service/CMakeLists.txt
src/itc/widget_viewer_evas/CMakeLists.txt
src/itc/wifi-direct/CMakeLists.txt
src/itc/wifi/CMakeLists.txt
src/utc/accounts-svc/CMakeLists.txt
src/utc/app-manager/CMakeLists.txt
src/utc/appcore-agent/CMakeLists.txt
src/utc/appcore-watch/CMakeLists.txt
src/utc/appcore-widget/CMakeLists.txt
src/utc/application/CMakeLists.txt
src/utc/attach-panel/CMakeLists.txt
src/utc/audio-io/CMakeLists.txt
src/utc/badge/CMakeLists.txt
src/utc/base-utils/CMakeLists.txt
src/utc/bluetooth/CMakeLists.txt
src/utc/bundle/CMakeLists.txt
src/utc/cairo/CMakeLists.txt
src/utc/calendar-service2/CMakeLists.txt
src/utc/camera/CMakeLists.txt
src/utc/capi-maps-service/CMakeLists.txt
src/utc/capi-media-streamer/CMakeLists.txt
src/utc/capi-media-vision/CMakeLists.txt
src/utc/capi-message-port/CMakeLists.txt
src/utc/capi-ui-inputmethod-manager/CMakeLists.txt
src/utc/capi-ui-inputmethod/CMakeLists.txt
src/utc/connection/CMakeLists.txt
src/utc/contacts-service2/CMakeLists.txt
src/utc/context/CMakeLists.txt
src/utc/d2d-conv-manager/CMakeLists.txt
src/utc/dali-adaptor/CMakeLists.txt
src/utc/dali-core/CMakeLists.txt
src/utc/dali-toolkit/CMakeLists.txt
src/utc/data-control/CMakeLists.txt
src/utc/device/CMakeLists.txt
src/utc/dlog/CMakeLists.txt
src/utc/efl-ext/CMakeLists.txt
src/utc/efl-util/CMakeLists.txt
src/utc/email/CMakeLists.txt
src/utc/eom/CMakeLists.txt
src/utc/fido-client/CMakeLists.txt
src/utc/geofence-manager/CMakeLists.txt
src/utc/http/CMakeLists.txt
src/utc/image-util/CMakeLists.txt
src/utc/iotcon/CMakeLists.txt
src/utc/key-manager/CMakeLists.txt
src/utc/libfeedback/CMakeLists.txt
src/utc/libstorage/CMakeLists.txt
src/utc/libstorage64/CMakeLists.txt
src/utc/location-manager/CMakeLists.txt
src/utc/media-content/CMakeLists.txt
src/utc/media-controller/CMakeLists.txt
src/utc/media-key/CMakeLists.txt
src/utc/mediacodec/CMakeLists.txt
src/utc/mediademuxer/CMakeLists.txt
src/utc/mediamuxer/CMakeLists.txt
src/utc/mediatool/CMakeLists.txt
src/utc/messages/CMakeLists.txt
src/utc/metadata-editor/CMakeLists.txt
src/utc/metadata-extractor/CMakeLists.txt
src/utc/mime-type/CMakeLists.txt
src/utc/minicontrol/CMakeLists.txt
src/utc/motion/CMakeLists.txt
src/utc/mtp/CMakeLists.txt
src/utc/native-common/CMakeLists.txt
src/utc/nfc/CMakeLists.txt
src/utc/notification/CMakeLists.txt
src/utc/nsd/CMakeLists.txt
src/utc/oauth2/CMakeLists.txt
src/utc/package-manager/CMakeLists.txt
src/utc/phonenumber-utils/CMakeLists.txt
src/utc/player/CMakeLists.txt
src/utc/privilege-info/CMakeLists.txt
src/utc/push/CMakeLists.txt
src/utc/radio/CMakeLists.txt
src/utc/recorder/CMakeLists.txt
src/utc/runtime-info/CMakeLists.txt
src/utc/screen-mirroring/CMakeLists.txt
src/utc/sensor/CMakeLists.txt
src/utc/service-adaptor/CMakeLists.txt
src/utc/shortcut/CMakeLists.txt
src/utc/smartcard/CMakeLists.txt
src/utc/sound-manager/CMakeLists.txt
src/utc/streamrecorder/CMakeLists.txt
src/utc/stt/CMakeLists.txt
src/utc/sync-manager/CMakeLists.txt
src/utc/system-info/CMakeLists.txt
src/utc/system-settings/CMakeLists.txt
src/utc/tbm/CMakeLists.txt
src/utc/telephony/CMakeLists.txt
src/utc/thumbnail-util/CMakeLists.txt
src/utc/tone-player/CMakeLists.txt
src/utc/trace/CMakeLists.txt
src/utc/tts/CMakeLists.txt
src/utc/url-download/CMakeLists.txt
src/utc/video-util/CMakeLists.txt
src/utc/voice-control-elm/CMakeLists.txt
src/utc/voice-control/CMakeLists.txt
src/utc/vpn/CMakeLists.txt
src/utc/wav-player/CMakeLists.txt
src/utc/webkit2/CMakeLists.txt
src/utc/widget_service/CMakeLists.txt
src/utc/widget_viewer_evas/CMakeLists.txt
src/utc/wifi-direct/CMakeLists.txt
src/utc/wifi/CMakeLists.txt
tct32_common_iot_asan.conf [new file with mode: 0755]
tct32_mobile_asan.conf [new file with mode: 0755]
tct32_tv_asan.conf [new file with mode: 0755]
tct32_wearable_asan.conf [new file with mode: 0755]
tct64_common_iot_asan.conf [new file with mode: 0755]
tct64_mobile_asan.conf [new file with mode: 0755]
tct64_tv_asan.conf [new file with mode: 0755]
tct64_wearable_asan.conf [new file with mode: 0755]
templates/external_wrapper_asan/external_wrapper.sh [new file with mode: 0755]
templates/tct-package-asan/inst.sh [new file with mode: 0755]

diff --git a/README_ASAN.txt b/README_ASAN.txt
new file mode 100644 (file)
index 0000000..21eddba
--- /dev/null
@@ -0,0 +1,29 @@
+================================================================================================
+Date: 12 June 2016
+Purpose: Instruction Guide for TCT Build/Install/Execution using Address Sanitizer
+================================================================================================
+
+
+=====================================Description================================================
+TCT Facilitates executing any itc/ctc/utc module using Address Sanitizer (ASAN).
+Currently this support has been provided for mobile (armv7l only).
+In the future we will extend this support to wearable/tv/common_iot profile also with development in asan library for these profiles.
+================================================================================================
+
+=====================Build/Install/Execution Steps for any TCT Module==========================
+a) ./scripts/init.sh
+b) Download and Unzip ASAN RPM directory (ASAN_REPO_RPM_BASE.zip) to your local system from RPM source location: "http://suprem.sec.samsung.net/confluence/pages/editpage.action?pageId=54213582"
+c) In the tcbuild file, replace  '<ASAN_RPM_LOCAL_DIRECTORY>' with ASAN_REPO_RPM_BASE folder path (It should be absolute path).
+d) Build TCT module : sudo ./tcbuild build_asan <build_type> <module_name> <arch_type> <device_type>
+e) Install TCT Module : sudo ./tcbuild install_asan <build_type> <module_name> <arch_type> <device_type>
+               <build_type> = itc|ctc|utc
+       <arch_type> = armv7l (currently only this is supported)
+       <device_type> = mobile (currently only this is supported)
+f) Execute using tct-manager tool.
+================================================================================================
+
+
+=====================================Troubleshooting===============================================
+For any troubleshooting, please contact its developer: Satyajit Anand (satyajit.a@samsung.com)
+===================================================================================================
index 8af0299..97d76b3 100755 (executable)
@@ -28,20 +28,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 1deddd4..da360fe 100755 (executable)
@@ -29,20 +29,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 21e6c9f..09e2794 100755 (executable)
@@ -31,20 +31,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 94c7174..6c73903 100755 (executable)
@@ -28,20 +28,32 @@ Native API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 5d1d50f..67c3794 100755 (executable)
@@ -30,20 +30,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 6e01ea5..c8a3a97 100755 (executable)
@@ -29,20 +29,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 663ec60..55f40a8 100755 (executable)
@@ -29,20 +29,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 92e7557..976565d 100755 (executable)
@@ -31,20 +31,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 452c4e0..bab754a 100755 (executable)
@@ -28,20 +28,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 9df5bde..4f9c8a9 100755 (executable)
@@ -44,20 +44,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 2ee5f2f..f457244 100755 (executable)
@@ -116,16 +116,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ab48493..bcc482f 100755 (executable)
@@ -32,20 +32,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 0db3d1e..2442a46 100755 (executable)
@@ -29,20 +29,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 447d9c4..0c97641 100755 (executable)
@@ -29,20 +29,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ffa1b07..04131af 100755 (executable)
@@ -30,20 +30,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 7479e0c..224eda5 100755 (executable)
@@ -28,20 +28,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 3957c18..89ca07c 100755 (executable)
@@ -30,20 +30,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif 
 
 make %{?jobs:-j%jobs}
index 4d1e629..1241750 100755 (executable)
@@ -35,20 +35,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a316569..099576b 100755 (executable)
@@ -29,20 +29,32 @@ Core API Compatibility Test (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="ctc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4f5ffbf..2632794 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 43d4c07..3de74de 100755 (executable)
@@ -15,6 +15,7 @@ BuildRequires:        cmake
 BuildRequires: pkgconfig(bundle)
 BuildRequires: pkgconfig(vconf)
 BuildRequires: pkgconfig(aul)
+BuildRequires: pkgconfig(ail)
 BuildRequires: pkgconfig(glib-2.0)
 BuildRequires: pkgconfig(gobject-2.0)
 BuildRequires: pkgconfig(capi-base-common)
@@ -32,20 +33,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 67ad4c3..8ad203b 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index f40938d..fc13a82 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 9bb302f..eb0ecb1 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 80b7944..92b2462 100755 (executable)
@@ -31,20 +31,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index dd29181..de5eec3 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 9ae690a..3e133e6 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 6313c73..91b5936 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 12aa8fb..f138a45 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 2acf19f..9290cc3 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 1ea84ed..825c4e3 100755 (executable)
@@ -33,20 +33,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 43a6648..c7e2a6d 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4c198bc..b8d0bf3 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ccaa136..b2c865c 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a4e41c0..ee06cba 100755 (executable)
@@ -38,20 +38,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index cd90cdb..17ae979 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8f440a9..6b692ea 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 048e296..594fc4e 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 9a77bfa..18b955b 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 5c7df45..441e527 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 5803fa6..895008c 100755 (executable)
@@ -31,20 +31,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ed336c0..0e19370 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 3311e67..acbc1b5 100755 (executable)
@@ -32,20 +32,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 5b44d13..08d53bc 100755 (executable)
@@ -43,20 +43,32 @@ export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 %define _des_dir %{APP_PATH}%{name}/data/
 %define src_dir media
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 2a65afa..2aea354 100755 (executable)
@@ -43,20 +43,32 @@ export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 %define _des_dir %{APP_PATH}%{name}/data/
 %define src_dir media
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index f32427f..ce3bb38 100755 (executable)
@@ -41,20 +41,32 @@ export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 %define _des_dir %{APP_PATH}%{name}/data/
 %define src_dir media
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 40837be..8029ab7 100755 (executable)
@@ -32,20 +32,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 58a6af9..90a591b 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 3aacee7..eabfb53 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index c23ef52..80dda8e 100755 (executable)
@@ -44,20 +44,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
- %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
- %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 64c10ed..fdc3081 100755 (executable)
@@ -32,20 +32,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 260687e..57e5521 100755 (executable)
@@ -27,20 +27,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0 
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 7c3c108..af1f203 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 75b6989..4c2fac9 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index c50c38b..9708747 100755 (executable)
@@ -37,20 +37,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 19b94a8..a3ff583 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index e721159..2abad78 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 2e6c0da..fcc8b6e 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8e3b421..813a1d9 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4ba9636..fabbe79 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index bb98030..cb102dd 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4bfe9f1..d78a8af 100755 (executable)
@@ -35,20 +35,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a9ee0f6..68cb8d6 100755 (executable)
@@ -34,20 +34,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index e25b603..e7d189d 100755 (executable)
@@ -31,20 +31,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index db42e00..1a3e2a7 100755 (executable)
@@ -38,20 +38,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 0157793..9ca0c6c 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 033758b..6bb3e78 100755 (executable)
@@ -33,20 +33,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index b94cda3..ff67306 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index fa51302..37a9a7c 100755 (executable)
@@ -31,20 +31,32 @@ p%prep
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 make %{?jobs:-j%jobs}
 
index 2a70db6..b67aaed 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 20be429..a2c824a 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4906d42..8c9f583 100755 (executable)
@@ -33,20 +33,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 2a532a0..ebfff45 100755 (executable)
@@ -34,20 +34,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ae7bf29..25ca98f 100755 (executable)
@@ -32,20 +32,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ed62390..ccfb731 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8f549b8..1af9992 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 3200b4e..8f3fcc9 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 43360a1..11de6ee 100755 (executable)
@@ -32,20 +32,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 84d7ad3..6569dd7 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8dbfaad..536bcbc 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index f5fba71..911c1a8 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 135dce5..a547df5 100755 (executable)
@@ -32,20 +32,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index bec1834..3466988 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 6b9831a..8ddb8f0 100755 (executable)
@@ -34,20 +34,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 274f6b6..289904f 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index cd8adcc..2e914b4 100755 (executable)
@@ -38,20 +38,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 make %{?jobs:-j%jobs}
 
index eac8ba0..95b91b6 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ab1ea3e..5d878b3 100755 (executable)
@@ -27,20 +27,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ccdac29..fa64c2a 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index d595d95..6ca810d 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index fb3b24c..c89ea9d 100755 (executable)
@@ -36,20 +36,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index b0de4c7..ee69d7e 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 769d9fd..e683855 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 0d4728a..b0c0ad4 100755 (executable)
@@ -35,20 +35,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 
index b0bc7bf..2a20fda 100755 (executable)
@@ -51,20 +51,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index c9990b2..e28e480 100755 (executable)
@@ -27,20 +27,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ab27768..3aa0794 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 298d60f..516a24f 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 9f46993..1e34538 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 26cceaa..adce6eb 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index b137ca2..1f50499 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index fd7681d..6133c09 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 46409cf..00655fe 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index d0900c0..12dced6 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4933c4c..bdc8d7e 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 make %{?jobs:-j%jobs}
 
index f67dee0..5d2a822 100755 (executable)
@@ -47,20 +47,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index b85e5c9..31efc27 100755 (executable)
@@ -46,20 +46,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 3ece1fc..534e73f 100755 (executable)
@@ -28,20 +28,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index f9fe37a..f67c7af 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index f19506d..7c34b2d 100755 (executable)
@@ -37,20 +37,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 928a13d..3750d7a 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a6f9945..72c2861 100755 (executable)
@@ -38,20 +38,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 1880646..91b7f84 100755 (executable)
@@ -29,20 +29,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 make %{?jobs:-j%jobs}
 
index f12dd94..88f1d7c 100755 (executable)
@@ -30,20 +30,32 @@ Native API Integration TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="itc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index f1372c7..175fb95 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 83be008..f4ac0e1 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8ae3bc3..6b62a82 100755 (executable)
@@ -25,20 +25,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 7965bf8..6e03b39 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index cd89c19..7b2050d 100755 (executable)
@@ -30,20 +30,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index aa568c4..5ef1bf7 100755 (executable)
@@ -32,20 +32,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index f6eda43..161132e 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a39d760..b3b51d3 100755 (executable)
@@ -28,18 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index dd675c7..b3df06a 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index e098fec..c9f7fce 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 601756d..891a45f 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
- %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
- %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index e2db524..c0d393e 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8a2836e..7faf018 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4cfc732..078fc01 100755 (executable)
@@ -34,20 +34,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index c7eca0b..5c29e04 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 9101e0c..7e4b162 100755 (executable)
@@ -30,20 +30,32 @@ export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
 %define _des_dir %{APP_PATH}%{name}/data/
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 9ab0cbd..da06b0a 100755 (executable)
@@ -38,20 +38,33 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
-%endif
 
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DRES_PATH="%{RES_PATH}"
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 20fc000..ef2f894 100755 (executable)
@@ -36,20 +36,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index fbc752e..29c14c1 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index d670d1f..e5d07b0 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 5be2326..6625da6 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index f363323..ab1c3b0 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
 #cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a2fb5bd..27fe771 100755 (executable)
@@ -34,20 +34,32 @@ Core API unit TC (%{name})
 %define PREFIX "%{_libdir}/%{name}"
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index e21e7a5..bc1ef75 100755 (executable)
@@ -37,20 +37,32 @@ Core API unit TC (%{name})
 %define PREFIX "%{_libdir}/%{name}"
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8d4d95f..26e0fd8 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ca2edfe..20b6d1e 100755 (executable)
@@ -36,20 +36,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 39d4998..3eee9a9 100755 (executable)
@@ -43,20 +43,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index e0e0feb..558fb4b 100755 (executable)
@@ -40,20 +40,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 7c392e8..966d6d2 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index eeb164d..8ab343e 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 15cf34e..07fa5c6 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 302a1a6..fdded62 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index c525dbf..6b97397 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8423772..9eb9d66 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a0b5d5d..04b9896 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 29141a9..9e847af 100755 (executable)
@@ -40,20 +40,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 87ce0d7..e498833 100755 (executable)
@@ -34,20 +34,32 @@ export FFLAGS="$FFLAGS -DTIZEN_DEVICE"
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index c6e0fbd..964e599 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
 #cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a23cca8..48376c1 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 30320d0..793d20d 100755 (executable)
@@ -25,20 +25,32 @@ Core API unit TC (%{name})
 
 %build
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 10ee718..74825ad 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if 0%{?DEVICE_BUILD_TYPE_MOBILE:1}
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DDEVICE_BUILD_TYPE="mobile"
-%endif
-
-%if 0%{?DEVICE_BUILD_TYPE_WEARABLE:1}
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DDEVICE_BUILD_TYPE="wearable"
-%endif
-
-%if 0%{?DEVICE_BUILD_TYPE_TV:1}
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DCMAKE_INSTALL_PREFIX=%{_prefix} -DDEVICE_BUILD_TYPE="tv"
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a8a659d..c58e1a3 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4ee006c..f3cf5c1 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a9b4f5a..ba3bc6d 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -D_FILE_OFFSET_BITS=64 -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -D_FILE_OFFSET_BITS=64 -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -D_FILE_OFFSET_BITS=64 -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 1b73550..ec1a629 100755 (executable)
@@ -31,20 +31,32 @@ export FFLAGS="$FFLAGS -DTIZEN_DEVICE"
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a506581..5ac23bc 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 0efe249..197bef9 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 67197b8..2d1dd4f 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ad076fd..ef049fa 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 90c74d8..99a13a9 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 2628f9e..d84bdc6 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 6e8196b..e0cf10b 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index b7f2581..58ba3e0 100755 (executable)
@@ -34,20 +34,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 50148da..c7adf4b 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 3fb110c..648c5dc 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 25365e7..2d0b69c 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 77c30d6..ee58273 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index f6ffa1e..db025b3 100755 (executable)
@@ -32,20 +32,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 5a6e72e..0b32a87 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8c864d3..34217b9 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4d14cbc..2dd8129 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a38f450..8f1ea67 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index dfd9412..ec49fa0 100755 (executable)
@@ -35,20 +35,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 9ea12ee..62230fd 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index ae376e2..fc0e3dc 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 497954d..d020e16 100755 (executable)
@@ -32,20 +32,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 
index f7add6a..fb06352 100755 (executable)
@@ -31,20 +31,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8f43846..5c69551 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 523729f..c026160 100755 (executable)
@@ -30,20 +30,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 6d559cd..2e90fed 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 653cad8..33f2d1a 100755 (executable)
@@ -30,20 +30,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 0abe78e..39a970e 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8b9e63e..0830500 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 make %{?jobs:-j%jobs}
 
index 7829c89..6080cd4 100755 (executable)
@@ -31,20 +31,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index b87bb6f..7ebecdb 100755 (executable)
@@ -33,20 +33,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 5df13f2..ec6736a 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index fd1f867..59faa55 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 4570b95..7f85263 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index db0f5b1..4762f08 100755 (executable)
@@ -31,20 +31,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index a6f7a2b..e52108a 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 2aa09e1..1011c68 100755 (executable)
@@ -32,20 +32,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 2ceca13..dca74e0 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 89d2947..bffd99c 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 7e1ffe7..62520a7 100755 (executable)
@@ -26,20 +26,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 54e895b..8af0d86 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 313ac54..cfcb4b1 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 3e08c0d..4498d4b 100755 (executable)
@@ -27,17 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 82dc15a..c7dec3c 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-#%if %{?DEVICE_BUILD_TYPE_TV:1}0
-#cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-#%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8e79382..8338434 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 9fda849..f680b19 100755 (executable)
@@ -29,20 +29,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 0b11a55..60b90b0 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index d5ba6bb..b0ed9f3 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 6d7b44b..fe43af8 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index d7e6e23..1037731 100755 (executable)
@@ -33,20 +33,32 @@ export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
 #cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DCMAKE_INSTALL_PREFIX=%{_prefix}
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 03041a0..79aa249 100755 (executable)
@@ -28,17 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 1879a5e..8973b2b 100755 (executable)
@@ -35,20 +35,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 8bed9fd..696be99 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 14a2837..adeea31 100755 (executable)
@@ -28,20 +28,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 073e737..ef8f750 100755 (executable)
@@ -31,20 +31,32 @@ Core API unit TC (%{name})
 
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index bda26a0..68ea890 100755 (executable)
@@ -27,20 +27,32 @@ Core API unit TC (%{name})
 export LDFLAGS+="-Wl,--rpath=%{PREFIX} -Wl,--as-needed"
 
 #cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_TV:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DCMAKE_INSTALL_PREFIX=%{_prefix}
-%endif
-
-%if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
-cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%if %{?ASAN_BUILD:1}0
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="true" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+%else
+       %if %{?DEVICE_BUILD_TYPE_MOBILE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="mobile" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_WEARABLE:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="wearable" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_TV:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="tv" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
+       %if %{?DEVICE_BUILD_TYPE_COMMON_IOT:1}0
+       cmake . -DMODULE="%{MODULE_NAME}" -DBUILDTCTYPE="utc" -DDEVICE_BUILD_TYPE="common_iot" -DASANBUILD="false" -DCMAKE_INSTALL_PREFIX=%{_prefix}
+       %endif
 %endif
 
 make %{?jobs:-j%jobs}
index 2cec0df..2261384 100755 (executable)
@@ -31,7 +31,14 @@ d_showVar PROJECT_DIR
 
 TC_RUN_COUNT=1
 
-if [ "build" == "$1" ] || [ "install" == "$1" ] || [ "install_coverage" == "$1" ] || [ "install_custom" == "$1" ]; then
+ASAN="false"
+if [ "build_asan" == "$1" ] || [ "install_asan" == "$1" ]; then
+       ASAN="true"
+fi
+
+
+if [ "build" == "$1" ] || [ "build_asan" == "$1" ] || [ "install" == "$1" ] || [ "install_asan" == "$1" ] || [ "install_coverage" == "$1" ] || [ "install_custom" == "$1" ]; then
+
        if   [ "$2" = "mobile"  ] || [ "$3" = "mobile"  ] || [ "$4" = "mobile"  ] || [ "$5" = "mobile"  ] ; then
                BUILD_DEVICE_TYPE="mobile"
        elif [ "$2" = "wearable" ] || [ "$3" = "wearable"  ] || [ "$4" = "wearable"  ] || [ "$5" = "wearable"  ]; then
@@ -47,31 +54,57 @@ if [ "build" == "$1" ] || [ "install" == "$1" ] || [ "install_coverage" == "$1"
 
        if   [ "$2" = "armv7l"  ] || [ "$3" = "armv7l"  ] || [ "$4" = "armv7l"  ] || [ "$5" = "armv7l"  ]; then
                ARCH="armv7l"
-               if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
-                       TCCONF=tct32_mobile.conf
-               elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
-                       TCCONF=tct32_wearable.conf
-               elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
-                       TCCONF=tct32_tv.conf
-               elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
-                       TCCONF=tct32_common_iot.conf
-               fi
+               if [ $ASAN == "false" ]; then
+                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                               TCCONF=tct32_mobile.conf
+                       elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                               TCCONF=tct32_wearable.conf
+                       elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                               TCCONF=tct32_tv.conf
+                       elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                               TCCONF=tct32_common_iot.conf
+                       fi
+               else
+                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                               TCCONF=tct32_mobile_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                               TCCONF=tct32_wearable_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                               TCCONF=tct32_tv_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                               TCCONF=tct32_common_iot_asan.conf
+                       fi
+               fi
        elif [ "$2" = "aarch64" ] || [ "$3" = "aarch64"  ] || [ "$4" = "aarch64"  ] || [ "$5" = "aarch64"  ]; then
                ARCH="aarch64"
-               if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+               if [ $ASAN == "false" ]; then
+                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
                        TCCONF=tct64_mobile.conf
-               elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
-                       TCCONF=tct64_wearable.conf
-               elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
-                       TCCONF=tct64_tv.conf
-               elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
-                       TCCONF=tct64_common_iot.conf
-               fi
+                       elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                               TCCONF=tct64_wearable.conf
+                       elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                               TCCONF=tct64_tv.conf
+                       elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                               TCCONF=tct64_common_iot.conf
+                       fi
+               else
+                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                               TCCONF=tct64_mobile_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                               TCCONF=tct64_wearable_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                               TCCONF=tct64_tv_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                               TCCONF=tct64_common_iot_asan.conf
+                       fi
+               fi
        else
                echo "Add argument 'architecture (armv7l or aarch64)'"
                exit
        fi
+fi
 
+if [ $ASAN == "false" ]; then
        if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
                RPM_DIR="$HOME/GBS-ROOT-TCT-MOBILE/local/repos/device/$ARCH/RPMS"
        elif [ $BUILD_DEVICE_TYPE == "wearable"  ]; then
@@ -84,6 +117,20 @@ if [ "build" == "$1" ] || [ "install" == "$1" ] || [ "install_coverage" == "$1"
                echo "Add argument 'device build type (mobile or wearable or tv or common_iot)'"
                exit
        fi
+else
+       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+               RPM_DIR="$HOME/GBS-ROOT-TCT-MOBILE-ASAN/local/repos/device/$ARCH/RPMS"
+       elif [ $BUILD_DEVICE_TYPE == "wearable"  ]; then
+               RPM_DIR="$HOME/GBS-ROOT-TCT-WEARABLE-ASAN/local/repos/device/$ARCH/RPMS"
+       elif [ $BUILD_DEVICE_TYPE == "tv"  ]; then
+               RPM_DIR="$HOME/GBS-ROOT-TCT-TV-ASAN/local/repos/device/$ARCH/RPMS"
+       elif [ $BUILD_DEVICE_TYPE == "common_iot"  ]; then
+               RPM_DIR="$HOME/GBS-ROOT-TCT-COMMON_IOT-ASAN/local/repos/device/$ARCH/RPMS"
+       else
+               echo "Add argument 'device build type (mobile or wearable or tv)'"
+               exit
+       fi
+       ASAN_BUILD_PATH="$RPM_DIR/../../../../BUILD-ROOTS/scratch.$ARCH.0/home/abuild/rpmbuild/BUILD/"
 fi
 
 if [ "$1" = "install_custom"  ]; then
@@ -102,7 +149,7 @@ INSTALL_PKG_COUNT=0
 INSTALL_MODE=0
 UNSUPPORTED_FILE="tct_unsupported.txt"
 
-if [ "build" == "$1" ]; then
+if [ "build" == "$1" ] || [ "build_asan" == "$1" ]; then
        echo ""
        echo "-------------- Setting $1 Configuration --------------"
        echo "DEVICE MODE = '$BUILD_DEVICE_TYPE'"
@@ -252,33 +299,58 @@ PREFIX="native"
                        if [ -n "$filename" ]; then
                                rm -f $filename
                        fi
-                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
-                               echo "DEVICE BUILD TYPE = MOBILE"
-                               gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_MOBILE $BUILD_DEVICE_TYPE" -P device | \
+                       if [ $ASAN == "false" ]; then
+                               if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                                       echo "DEVICE BUILD TYPE = MOBILE"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_MOBILE $BUILD_DEVICE_TYPE" -P device | \
                            tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
                                                           -e 's/warning:/\x1b[93m&\x1b[0m/'
-                       fi
-                       if [ $BUILD_DEVICE_TYPE == "wearable" ]; then
-                               echo "DEVICE BUILD TYPE = WEARABLE"
-                               gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_WEARABLE $BUILD_DEVICE_TYPE" -P device | \
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                                       echo "DEVICE BUILD TYPE = WEARABLE"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_WEARABLE $BUILD_DEVICE_TYPE" -P device | \
                            tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
                                                           -e 's/warning:/\x1b[93m&\x1b[0m/'
-                       fi
-                       if [ $BUILD_DEVICE_TYPE == "tv" ]; then
-                               echo "DEVICE BUILD TYPE = TV"
-                               gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_TV $BUILD_DEVICE_TYPE" -P device | \
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                                       echo "DEVICE BUILD TYPE = TV"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_TV $BUILD_DEVICE_TYPE" -P device | \
                            tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
                                                           -e 's/warning:/\x1b[93m&\x1b[0m/'
-                       fi
-                       if [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
-                               echo "DEVICE BUILD TYPE = COMMON_IOT"
-                               gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_COMMON_IOT $BUILD_DEVICE_TYPE" -P device | \
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                                       echo "DEVICE BUILD TYPE = COMMON_IOT"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_COMMON_IOT $BUILD_DEVICE_TYPE" -P device | \
+                           tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
+                                                          -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
+                       else
+                               if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                                       echo "DEVICE BUILD TYPE = MOBILE"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec  --repository <ASAN_RPM_LOCAL_DIRECTORY> --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "ASAN_BUILD $ASAN" --define "DEVICE_BUILD_TYPE_MOBILE $BUILD_DEVICE_TYPE" -P device | \
+                           tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
+                                                          -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                                       echo "DEVICE BUILD TYPE = WEARABLE"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --repository <ASAN_RPM_LOCAL_DIRECTORY> --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "ASAN_BUILD $ASAN" --define "DEVICE_BUILD_TYPE_WEARABLE $BUILD_DEVICE_TYPE" -P device | \
+                           tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
+                                                          -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                                       echo "DEVICE BUILD TYPE = TV"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --repository <ASAN_RPM_LOCAL_DIRECTORY> --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "ASAN_BUILD $ASAN" --define "DEVICE_BUILD_TYPE_TV $BUILD_DEVICE_TYPE" -P device | \
                            tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
                                                           -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                                       echo "DEVICE BUILD TYPE = COMMON_IOT"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --repository <ASAN_RPM_LOCAL_DIRECTORY> --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "ASAN_BUILD $ASAN" --define "DEVICE_BUILD_TYPE_COMMON_IOT $BUILD_DEVICE_TYPE" -P device | \
+                           tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
+                                                          -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
                        fi
-                       #gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" -P device | \
-                          # tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
-                           #                               -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               
                        CheckBuildFailStatus $1 $2
                fi
        else
@@ -554,12 +626,16 @@ function inst {
                                cp -rf src/$1/$2/res/$BUILD_DEVICE_TYPE/* /tmp/$TCT_DIR/res/
                        fi
                        #copy ext_wrapper.sh
-                       if [ $INSTALL_MODE == 0 ]; then
-                               cp templates/external_wrapper_execution/external_wrapper.sh /tmp/$TCT_DIR/
-                       elif [ $INSTALL_MODE == 1 ]; then
-                               cp templates/external_wrapper_coverage/external_wrapper.sh /tmp/$TCT_DIR/
+                       if [ $ASAN == "true" ]; then
+                               cp templates/external_wrapper_asan/external_wrapper.sh /tmp/$TCT_DIR/
                        else
-                               cp templates/external_wrapper_execution/external_wrapper.sh /tmp/$TCT_DIR/
+                               if [ $INSTALL_MODE == 0 ]; then
+                                       cp templates/external_wrapper_execution/external_wrapper.sh /tmp/$TCT_DIR/
+                               elif [ $INSTALL_MODE == 1 ]; then
+                                       cp templates/external_wrapper_coverage/external_wrapper.sh /tmp/$TCT_DIR/
+                               else
+                                       cp templates/external_wrapper_execution/external_wrapper.sh /tmp/$TCT_DIR/
+                               fi
                        fi
                        # rpm
                        echo "---- Copying rpm package to /tmp/$TCT_DIR package"
@@ -573,11 +649,17 @@ function inst {
                        if [ $? -ne 0 ]; then echo "Aborting..."; exit 1; fi
                        # inst.sh
                        echo "---- Generating /tmp/$TCT_DIR/inst.sh file"
-                       sed -e "s:%{PKG_NAME}:\"$PKG_NAME\":g" -e "s:%{PKG_FULLNAME}:\"$PKG_FNAME\":g" \
-                           -e "s:%{PKG_DIR}:\"$DEVICE_SUITE_TARGET_30/tct/$TCT_DIR\":g" -e "s:%{MOD_NAME}:\"$MOD_NAME\":g" \
-                           templates/tct-package/inst.sh > /tmp/$TCT_DIR/inst.sh
+                       if [ $ASAN == "true" ]; then
+                               sed -e "s:%{PKG_NAME}:\"$PKG_NAME\":g" -e "s:%{PKG_FULLNAME}:\"$PKG_FNAME\":g" \
+                                   -e "s:%{PKG_DIR}:\"$DEVICE_SUITE_TARGET_30/tct/$TCT_DIR\":g" -e "s:%{MOD_NAME}:\"$MOD_NAME\":g" \
+                                   templates/tct-package-asan/inst.sh > /tmp/$TCT_DIR/inst.sh
+                       else
+                               sed -e "s:%{PKG_NAME}:\"$PKG_NAME\":g" -e "s:%{PKG_FULLNAME}:\"$PKG_FNAME\":g" \
+                                   -e "s:%{PKG_DIR}:\"$DEVICE_SUITE_TARGET_30/tct/$TCT_DIR\":g" -e "s:%{MOD_NAME}:\"$MOD_NAME\":g" \
+                                   templates/tct-package/inst.sh > /tmp/$TCT_DIR/inst.sh
+                       fi
                        chmod a+x /tmp/$TCT_DIR/inst.sh
-                       # itc.xml
+                       # tests.xml
                        echo "---- Generating /tmp/$TCT_DIR"
                        if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
                                scripts/tctestsgen.sh $MOD_NAME /tmp/$TCT_DIR $BUILDTC_TYPE mobile
@@ -603,6 +685,27 @@ function inst {
                        fi
                        
                        if [ $? -ne 0 ]; then echo "Aborting..."; exit 1; fi
+                       
+                       # if asan install
+                       if [ $ASAN == "true" ]; then
+                               EXE_SUFFIX=$1
+                               if [ $1 == "utc" ]; then
+                                        EXE_SUFFIX="core"
+                               fi
+                               if [ $1 == "itc" ]; then
+                                        EXE_SUFFIX="native"
+                               fi
+                               EXE_NAME=tct-$MOD_NAME-$EXE_SUFFIX
+                               asan_exe_file_path=`find $ASAN_BUILD_PATH -name $EXE_NAME`
+                               if [ "$asan_exe_file_path" = "" ]; then
+                                        echo "---- Could not find ($EXE_NAME) inside GBS-ROOT scratch box folder location"
+                                        echo "---- address sanitizer may not work properly (execution will be with stripped binary) [WARNING]"         
+                               else
+                                        echo "---- Copying $EXE_NAME [ASAN Binary] inside /tmp/$TCT_DIR/"
+                                        cp $asan_exe_file_path /tmp/$TCT_DIR/
+                               fi
+                       fi
+                       
                        # zip
                        echo "---- Preparing /tmp/tct/packages/tct-$MOD_NAME-$PREFIX_PKG_NAME-$TAG_SPEC_PKG_NAME-3.0.zip file"
                        # clear old zips
@@ -671,7 +774,7 @@ function RenameSpecAndCheckBuildFail {
 
 function helpusage {
 # usage note
-    echo "Usage: `basename $0` <addmod|addmodcpp|rmmod|build|install|install_coverage|install_custom> <build_type> <module_name> <arch_type> <device_type>"
+    echo "Usage: `basename $0` <addmod|addmodcpp|rmmod|build|build_asan|install|install_asan|install_coverage|install_custom> <build_type> <module_name> <arch_type> <device_type>"
     echo "Usage: `basename $0` <download>"
     echo "<build_type> = itc|ctc|utc"
     echo "<arch_type> = armv7l|aarch64"
@@ -681,7 +784,9 @@ function helpusage {
     echo "       addmodcpp                     add a new 'cpp' module"
     echo "       rmmod                 remove a module"
     echo "       build                 performs GBS build with --keep-packs option"
+       echo "       build_asan         performs GBS build for Address Sanitizer"
     echo "       install               install packages for execution"
+       echo "       install_asan               install packages for Address Sanitizer"
     echo "       install_coverage      install packages for coverage"
     echo "       install_custom                install packages for custom"
     echo "       download              download rpm packages from obs link to GBS RPMS location"
@@ -706,7 +811,7 @@ elif [ "addmodcpp" == "$1" ]; then
 elif [ "rmmod" == "$1" ]; then
     # remove module
     rm_module $2 $3
-elif [ "build" == "$1" ]; then
+elif [ "build" == "$1" ] || [ "build_asan" == "$1" ]; then
     if [ -d ./BuildFailLogsDevice ];then
                rm -rf ./BuildFailLogsDevice
        fi
@@ -723,7 +828,7 @@ elif [ "download" == "$1" ]; then
        download
 #elif [ "update" == "$1" ]; then
 #      update
-elif [ "install" == "$1" ]; then
+elif [ "install" == "$1" ] || [ "install_asan" == "$1" ]; then
     # install
        INSTALL_PKG_COUNT=0
        INSTALL_MODE=0
@@ -791,3 +896,4 @@ else
     echo "Invalid subcommand: $1"
     helpusage
 fi
+
index fd6fc65..8e0b2b3 100755 (executable)
@@ -29,7 +29,16 @@ function d_print { if [ "$ARG" == "-d" -a -n "$1" ]; then echo -e "d >> $1"; fi
 PROJECT_DIR="$(cd "$(dirname $0)" && pwd)"
 d_showVar PROJECT_DIR
 
-if [ "build" == "$1" ] || [ "install" == "$1" ] || [ "install_coverage" == "$1" ]; then
+TC_RUN_COUNT=1
+
+ASAN="false"
+if [ "build_asan" == "$1" ] || [ "install_asan" == "$1" ]; then
+       ASAN="true"
+fi
+
+
+if [ "build" == "$1" ] || [ "build_asan" == "$1" ] || [ "install" == "$1" ] || [ "install_asan" == "$1" ] || [ "install_coverage" == "$1" ] || [ "install_custom" == "$1" ]; then
+
        if   [ "$2" = "mobile"  ] || [ "$3" = "mobile"  ] || [ "$4" = "mobile"  ] || [ "$5" = "mobile"  ] ; then
                BUILD_DEVICE_TYPE="mobile"
        elif [ "$2" = "wearable" ] || [ "$3" = "wearable"  ] || [ "$4" = "wearable"  ] || [ "$5" = "wearable"  ]; then
@@ -45,31 +54,57 @@ if [ "build" == "$1" ] || [ "install" == "$1" ] || [ "install_coverage" == "$1"
 
        if   [ "$2" = "i586"  ] || [ "$3" = "i586"  ] || [ "$4" = "i586"  ] || [ "$5" = "i586"  ]; then
                ARCH="i586"
-               if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
-                       TCCONF=tct32_mobile.conf
-               elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
-                       TCCONF=tct32_wearable.conf
-               elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
-                       TCCONF=tct32_tv.conf
-               elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
-                       TCCONF=tct32_common_iot.conf
-               fi
+               if [ $ASAN == "false" ]; then
+                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                               TCCONF=tct32_mobile.conf
+                       elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                               TCCONF=tct32_wearable.conf
+                       elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                               TCCONF=tct32_tv.conf
+                       elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                               TCCONF=tct32_common_iot.conf
+                       fi
+               else
+                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                               TCCONF=tct32_mobile_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                               TCCONF=tct32_wearable_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                               TCCONF=tct32_tv_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                               TCCONF=tct32_common_iot_asan.conf
+                       fi
+               fi
        elif [ "$2" = "x86_64" ] || [ "$3" = "x86_64"  ] || [ "$4" = "x86_64"  ] || [ "$5" = "x86_64"  ]; then
                ARCH="x86_64"
-               if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+               if [ $ASAN == "false" ]; then
+                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
                        TCCONF=tct64_mobile.conf
-               elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
-                       TCCONF=tct64_wearable.conf
-               elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
-                       TCCONF=tct64_tv.conf
-               elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
-                       TCCONF=tct64_common_iot.conf
-               fi
+                       elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                               TCCONF=tct64_wearable.conf
+                       elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                               TCCONF=tct64_tv.conf
+                       elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                               TCCONF=tct64_common_iot.conf
+                       fi
+               else
+                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                               TCCONF=tct64_mobile_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                               TCCONF=tct64_wearable_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                               TCCONF=tct64_tv_asan.conf
+                       elif [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                               TCCONF=tct64_common_iot_asan.conf
+                       fi
+               fi
        else
                echo "Add argument 'architecture (i586 or x86_64)'"
                exit
        fi
+fi
 
+if [ $ASAN == "false" ]; then
        if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
                RPM_DIR="$HOME/GBS-ROOT-TCT-MOBILE/local/repos/sdk/$ARCH/RPMS"
        elif [ $BUILD_DEVICE_TYPE == "wearable"  ]; then
@@ -82,6 +117,30 @@ if [ "build" == "$1" ] || [ "install" == "$1" ] || [ "install_coverage" == "$1"
                echo "Add argument 'sdk build type (mobile or wearable or tv or common_iot)'"
                exit
        fi
+else
+       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+               RPM_DIR="$HOME/GBS-ROOT-TCT-MOBILE-ASAN/local/repos/sdk/$ARCH/RPMS"
+       elif [ $BUILD_DEVICE_TYPE == "wearable"  ]; then
+               RPM_DIR="$HOME/GBS-ROOT-TCT-WEARABLE-ASAN/local/repos/sdk/$ARCH/RPMS"
+       elif [ $BUILD_DEVICE_TYPE == "tv"  ]; then
+               RPM_DIR="$HOME/GBS-ROOT-TCT-TV-ASAN/local/repos/sdk/$ARCH/RPMS"
+       elif [ $BUILD_DEVICE_TYPE == "common_iot"  ]; then
+               RPM_DIR="$HOME/GBS-ROOT-TCT-COMMON_IOT-ASAN/local/repos/sdk/$ARCH/RPMS"
+       else
+               echo "Add argument 'device build type (mobile or wearable or tv)'"
+               exit
+       fi
+       ASAN_BUILD_PATH="$RPM_DIR/../../../../BUILD-ROOTS/scratch.$ARCH.0/home/abuild/rpmbuild/BUILD/"
+fi
+
+if [ "$1" = "install_custom"  ]; then
+       if [[ $4 == ?(-)+([0-9]) ]]; then
+               TC_RUN_COUNT=$4
+       elif [[ $5 == ?(-)+([0-9]) ]]; then
+               TC_RUN_COUNT=$5
+       elif [[ $6 == ?(-)+([0-9]) ]]; then
+               TC_RUN_COUNT=$6
+       fi
 fi
        
 OBS_URL="http://168.219.209.58:82/TCT:/3.0/emulator/i586/"
@@ -90,7 +149,7 @@ INSTALL_PKG_COUNT=0
 INSTALL_MODE=0
 UNSUPPORTED_FILE="tct_unsupported.txt"
 
-if [ "build" == "$1" ]; then
+if [ "build" == "$1" ] || [ "build_asan" == "$1" ]; then
        echo ""
        echo "-------------- Setting $1 Configuration --------------"
        echo "DEVICE MODE = '$BUILD_DEVICE_TYPE'"
@@ -241,33 +300,58 @@ PREFIX="native"
                        if [ -n "$filename" ]; then
                                rm -f $filename
                        fi
-                       if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
-                               echo "DEVICE BUILD TYPE = MOBILE"
-                               gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_MOBILE $BUILD_DEVICE_TYPE" -P sdk | \
+                       if [ $ASAN == "false" ]; then
+                               if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                                       echo "DEVICE BUILD TYPE = MOBILE"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_MOBILE $BUILD_DEVICE_TYPE" -P sdk | \
                            tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
                                                           -e 's/warning:/\x1b[93m&\x1b[0m/'
-                       fi
-                       if [ $BUILD_DEVICE_TYPE == "wearable" ]; then
-                               echo "DEVICE BUILD TYPE = WEARABLE"
-                               gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_WEARABLE $BUILD_DEVICE_TYPE" -P sdk | \
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                                       echo "DEVICE BUILD TYPE = WEARABLE"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_WEARABLE $BUILD_DEVICE_TYPE" -P sdk | \
                            tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
                                                           -e 's/warning:/\x1b[93m&\x1b[0m/'
-                       fi
-                       if [ $BUILD_DEVICE_TYPE == "tv" ]; then
-                               echo "DEVICE BUILD TYPE = TV"
-                               gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_TV $BUILD_DEVICE_TYPE" -P sdk | \
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                                       echo "DEVICE BUILD TYPE = TV"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_TV $BUILD_DEVICE_TYPE" -P sdk | \
                            tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
                                                           -e 's/warning:/\x1b[93m&\x1b[0m/'
-                       fi
-                       if [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
-                               echo "DEVICE BUILD TYPE = COMMON_IOT"
-                               gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_COMMON_IOT $BUILD_DEVICE_TYPE" -P sdk | \
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                                       echo "DEVICE BUILD TYPE = COMMON_IOT"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "DEVICE_BUILD_TYPE_COMMON_IOT $BUILD_DEVICE_TYPE" -P sdk | \
+                           tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
+                                                          -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
+                       else
+                               if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
+                                       echo "DEVICE BUILD TYPE = MOBILE"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --repository <ASAN_RPM_LOCAL_DIRECTORY> --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "ASAN_BUILD $ASAN" --define "DEVICE_BUILD_TYPE_MOBILE $BUILD_DEVICE_TYPE" -P sdk | \
                            tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
                                                           -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "wearable" ]; then
+                                       echo "DEVICE BUILD TYPE = WEARABLE"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --repository <ASAN_RPM_LOCAL_DIRECTORY> --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "ASAN_BUILD $ASAN" --define "DEVICE_BUILD_TYPE_WEARABLE $BUILD_DEVICE_TYPE" -P sdk | \
+                           tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
+                                                          -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "tv" ]; then
+                                       echo "DEVICE BUILD TYPE = TV"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --repository <ASAN_RPM_LOCAL_DIRECTORY> --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "ASAN_BUILD $ASAN" --define "DEVICE_BUILD_TYPE_TV $BUILD_DEVICE_TYPE" -P sdk | \
+                           tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
+                                                          -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
+                               if [ $BUILD_DEVICE_TYPE == "common_iot" ]; then
+                                       echo "DEVICE BUILD TYPE = COMMON_IOT"
+                                       gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --repository <ASAN_RPM_LOCAL_DIRECTORY> --include-all --keep-packs --define "APP_PATH $APP_DIR" --define "INTERNAL_STORAGE_PATH $INTERNAL_STORAGE_DIR" --define "DEVICE_SUITE_TARGET_30 $DEVICE_SUITE_TARGET_30" --define "DEVICE_USER_30 $DEVICE_USER_30" --define "ASAN_BUILD $ASAN" --define "DEVICE_BUILD_TYPE_COMMON_IOT $BUILD_DEVICE_TYPE" -P sdk | \
+                           tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
+                                                          -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               fi
                        fi
-                       #gbs --conf $TCCONF build -A $ARCH --packaging-dir packaging/$1 --spec $PREFIX-$2-$TAG_SPEC.spec --include-all --keep-packs --define "APP_PATH $APP_DIR" -P device | \
-                          # tee build.log | stdbuf -o0 sed -e 's/error:/\x1b[1;91m&\x1b[0m/' \
-                           #                               -e 's/warning:/\x1b[93m&\x1b[0m/'
+                               
                        CheckBuildFailStatus $1 $2
                fi
        else
@@ -536,16 +620,23 @@ function inst {
                        echo "---- Creating /tmp/$TCT_DIR directory"
                        rm -r /tmp/opt > /dev/null 2>&1
                        mkdir -p /tmp/$TCT_DIR
+                       chmod -R 777 /tmp/$TCT_DIR
                        #copy res
                        if [ -d src/$1/$2/res/$BUILD_DEVICE_TYPE ]; then
                                mkdir /tmp/$TCT_DIR/res
                                cp -rf src/$1/$2/res/$BUILD_DEVICE_TYPE/* /tmp/$TCT_DIR/res/
                        fi
                        #copy ext_wrapper.sh
-                       if [ $INSTALL_MODE == 0 ]; then
-                               cp templates/external_wrapper_execution/external_wrapper.sh /tmp/$TCT_DIR/
+                       if [ $ASAN == "true" ]; then
+                               cp templates/external_wrapper_asan/external_wrapper.sh /tmp/$TCT_DIR/
                        else
-                               cp templates/external_wrapper_coverage/external_wrapper.sh /tmp/$TCT_DIR/
+                               if [ $INSTALL_MODE == 0 ]; then
+                                       cp templates/external_wrapper_execution/external_wrapper.sh /tmp/$TCT_DIR/
+                               elif [ $INSTALL_MODE == 1 ]; then
+                                       cp templates/external_wrapper_coverage/external_wrapper.sh /tmp/$TCT_DIR/
+                               else
+                                       cp templates/external_wrapper_execution/external_wrapper.sh /tmp/$TCT_DIR/
+                               fi
                        fi
                        # rpm
                        echo "---- Copying rpm package to /tmp/$TCT_DIR package"
@@ -559,11 +650,17 @@ function inst {
                        if [ $? -ne 0 ]; then echo "Aborting..."; exit 1; fi
                        # inst.sh
                        echo "---- Generating /tmp/$TCT_DIR/inst.sh file"
-                       sed -e "s:%{PKG_NAME}:\"$PKG_NAME\":g" -e "s:%{PKG_FULLNAME}:\"$PKG_FNAME\":g" \
-                           -e "s:%{PKG_DIR}:\"$DEVICE_SUITE_TARGET_30/tct/$TCT_DIR\":g" -e "s:%{MOD_NAME}:\"$MOD_NAME\":g" \
-                           templates/tct-package/inst.sh > /tmp/$TCT_DIR/inst.sh
+                       if [ $ASAN == "true" ]; then
+                               sed -e "s:%{PKG_NAME}:\"$PKG_NAME\":g" -e "s:%{PKG_FULLNAME}:\"$PKG_FNAME\":g" \
+                                   -e "s:%{PKG_DIR}:\"$DEVICE_SUITE_TARGET_30/tct/$TCT_DIR\":g" -e "s:%{MOD_NAME}:\"$MOD_NAME\":g" \
+                                   templates/tct-package-asan/inst.sh > /tmp/$TCT_DIR/inst.sh
+                       else
+                               sed -e "s:%{PKG_NAME}:\"$PKG_NAME\":g" -e "s:%{PKG_FULLNAME}:\"$PKG_FNAME\":g" \
+                                   -e "s:%{PKG_DIR}:\"$DEVICE_SUITE_TARGET_30/tct/$TCT_DIR\":g" -e "s:%{MOD_NAME}:\"$MOD_NAME\":g" \
+                                   templates/tct-package/inst.sh > /tmp/$TCT_DIR/inst.sh
+                       fi
                        chmod a+x /tmp/$TCT_DIR/inst.sh
-                       # itc.xml
+                       # tests.xml
                        echo "---- Generating /tmp/$TCT_DIR"
                        if [ $BUILD_DEVICE_TYPE == "mobile" ]; then
                                scripts/tctestsgen.sh $MOD_NAME /tmp/$TCT_DIR $BUILDTC_TYPE mobile
@@ -578,7 +675,38 @@ function inst {
                                exit 1;
                        fi
                        
+                       ## generate new tests.xml
+                       if [ $INSTALL_MODE == 2 ]; then #check memory leak
+                               echo " Generating new tests.xml: '/tmp/$TCT_DIR'"
+                               bash scripts/gentestsxml.sh /tmp/$TCT_DIR/ $TC_RUN_COUNT
+                               if [ $? -ne 0 ]; then
+                                       echo " gentestsxml script failed to generate new tests.xml at '$tct_tmpfolder/opt/tct-$TESTSUITE_NAME-native-$TEST_TYPE/' location. Please check for permission(try with sudo)"
+                               exit 1; 
+                               fi
+                       fi
+                       
                        if [ $? -ne 0 ]; then echo "Aborting..."; exit 1; fi
+                       
+                       # if asan install
+                       if [ $ASAN == "true" ]; then
+                               EXE_SUFFIX=$1
+                               if [ $1 == "utc" ]; then
+                                        EXE_SUFFIX="core"
+                               fi
+                               if [ $1 == "itc" ]; then
+                                        EXE_SUFFIX="native"
+                               fi
+                               EXE_NAME=tct-$MOD_NAME-$EXE_SUFFIX
+                               asan_exe_file_path=`find $ASAN_BUILD_PATH -name $EXE_NAME`
+                               if [ "$asan_exe_file_path" = "" ]; then
+                                        echo "---- Could not find ($EXE_NAME) inside GBS-ROOT scratch box folder location"
+                                        echo "---- address sanitizer may not work properly (execution will be with stripped binary) [WARNING]"         
+                               else
+                                        echo "---- Copying $EXE_NAME [ASAN Binary] inside /tmp/$TCT_DIR/"
+                                        cp $asan_exe_file_path /tmp/$TCT_DIR/
+                               fi
+                       fi
+                       
                        # zip
                        echo "---- Preparing /tmp/tct/packages/tct-$MOD_NAME-$PREFIX_PKG_NAME-$TAG_SPEC_PKG_NAME-3.0.zip file"
                        # clear old zips
@@ -593,22 +721,22 @@ function inst {
                                mkdir -p $TO_PKG_DIR/mobile
                                cp /tmp/tct/packages/tct-$MOD_NAME-$PREFIX_PKG_NAME-$TAG_SPEC_PKG_NAME-3.0.zip $TO_PKG_DIR/mobile/
                                echo "---- Updating the file $TO_PKG_DIR/pkg_infos/mobile_pkg_info.xml"
-                               scripts/tcpackageslistsgen.sh $MOD_NAME $TO_PKG_DIR/pkg_infos/mobile_pkg_info.xml 0 $BUILDTC_TYPE mobile
+                               scripts/tcpackageslistsgen.sh $MOD_NAME $TO_PKG_DIR/pkg_infos/mobile_pkg_info.xml 0 $BUILDTC_TYPE mobile $TC_RUN_COUNT
                        elif [ $BUILD_DEVICE_TYPE == "wearable"  ]; then
                                mkdir -p $TO_PKG_DIR/wearable
                                cp /tmp/tct/packages/tct-$MOD_NAME-$PREFIX_PKG_NAME-$TAG_SPEC_PKG_NAME-3.0.zip $TO_PKG_DIR/wearable/
                                echo "---- Updating the file $TO_PKG_DIR/pkg_infos/wearable_pkg_info.xml"
-                               scripts/tcpackageslistsgen.sh $MOD_NAME $TO_PKG_DIR/pkg_infos/wearable_pkg_info.xml 0 $BUILDTC_TYPE wearable
+                               scripts/tcpackageslistsgen.sh $MOD_NAME $TO_PKG_DIR/pkg_infos/wearable_pkg_info.xml 0 $BUILDTC_TYPE wearable $TC_RUN_COUNT
                        elif [ $BUILD_DEVICE_TYPE == "tv"  ]; then
                                mkdir -p $TO_PKG_DIR/tv
                                cp /tmp/tct/packages/tct-$MOD_NAME-$PREFIX_PKG_NAME-$TAG_SPEC_PKG_NAME-3.0.zip $TO_PKG_DIR/tv/
                                echo "---- Updating the file $TO_PKG_DIR/pkg_infos/tv_pkg_info.xml"
-                               scripts/tcpackageslistsgen.sh $MOD_NAME $TO_PKG_DIR/pkg_infos/tv_pkg_info.xml 0 $BUILDTC_TYPE tv
+                               scripts/tcpackageslistsgen.sh $MOD_NAME $TO_PKG_DIR/pkg_infos/tv_pkg_info.xml 0 $BUILDTC_TYPE tv $TC_RUN_COUNT
                        elif [ $BUILD_DEVICE_TYPE == "common_iot"  ]; then
                                mkdir -p $TO_PKG_DIR/common_iot
                                cp /tmp/tct/packages/tct-$MOD_NAME-$PREFIX_PKG_NAME-$TAG_SPEC_PKG_NAME-3.0.zip $TO_PKG_DIR/common_iot/
                                echo "---- Updating the file $TO_PKG_DIR/pkg_infos/common_iot_pkg_info.xml"
-                               scripts/tcpackageslistsgen.sh $MOD_NAME $TO_PKG_DIR/pkg_infos/common_iot_pkg_info.xml 0 $BUILDTC_TYPE common_iot
+                               scripts/tcpackageslistsgen.sh $MOD_NAME $TO_PKG_DIR/pkg_infos/common_iot_pkg_info.xml 0 $BUILDTC_TYPE common_iot $TC_RUN_COUNT
                        else
                                echo "Aborting... Add argument 'sdk build type (mobile or wearable or tv or common_iot)'"
                                exit 1;
@@ -647,7 +775,7 @@ function RenameSpecAndCheckBuildFail {
 
 function helpusage {
 # usage note
-    echo "Usage: `basename $0` <addmod|addmodcpp|rmmod|build|install|install_coverage> <build_type> <module_name> <arch_type> <device_type>"
+    echo "Usage: `basename $0` <addmod|addmodcpp|rmmod|build|build_asan|install|install_asan|install_coverage|install_custom> <build_type> <module_name> <arch_type> <device_type>"
     echo "Usage: `basename $0` <download>"
     echo "<build_type> = itc|ctc|utc"
     echo "<arch_type> = i586|x86_64"
@@ -657,8 +785,11 @@ function helpusage {
     echo "       addmodcpp                     add a new 'cpp' module"
     echo "       rmmod                 remove a module"
     echo "       build                 performs GBS build with --keep-packs option"
+       echo "       build_asan         performs GBS build for Address Sanitizer"
     echo "       install               install packages for execution"
+       echo "       install_asan               install packages for Address Sanitizer"
     echo "       install_coverage      install packages for coverage"
+    echo "       install_custom                install packages for custom"
     echo "       download              download rpm packages from obs link to GBS RPMS location"
     #echo "       update               update all the modules header file."
     echo "To build|install all the packages (itc,ctc and utc), usage: `basename $0` build|install|install_coverage <arch_type> <device_type>"
@@ -681,7 +812,7 @@ elif [ "addmodcpp" == "$1" ]; then
 elif [ "rmmod" == "$1" ]; then
     # remove module
     rm_module $2 $3
-elif [ "build" == "$1" ]; then
+elif [ "build" == "$1" ] || [ "build_asan" == "$1" ]; then
     if [ -d ./BuildFailLogsSDK ];then
                rm -rf ./BuildFailLogsSDK
        fi
@@ -698,7 +829,7 @@ elif [ "download" == "$1" ]; then
        download
 #elif [ "update" == "$1" ]; then
 #      update
-elif [ "install" == "$1" ]; then
+elif [ "install" == "$1" ] || [ "install_asan" == "$1" ]; then
     # install
        INSTALL_PKG_COUNT=0
        INSTALL_MODE=0
@@ -740,6 +871,27 @@ elif [ "install_coverage" == "$1" ]; then
        cat install.log
     fi
     rm install.log
+elif [ "install_custom" == "$1" ]; then
+    # install
+       INSTALL_PKG_COUNT=0
+       INSTALL_MODE=2
+    echo "**********************************************" > install.log
+    echo "Following packages get installed successfully:" >> install.log
+       if   [ "$2" = "i586"  ] || [ "$2" = "x86_64"  ] || [ "$2" = "mobile"  ] || [ "$2" = "wearable"  ] || [ "$2" = "tv"  ] || [ "$2" = "common_iot"  ]; then
+                       inst
+       elif   [ "$3" = "i586"  ] || [ "$3" = "x86_64"  ] || [ "$3" = "mobile"  ] || [ "$3" = "wearable"  ] || [ "$3" = "tv"  ] || [ "$3" = "common_iot"  ]; then
+                       inst $2
+       else
+               inst $2 $3
+       fi
+       
+    echo "" >> install.log
+    echo "Total Install PASS Count = $INSTALL_PKG_COUNT" >> install.log
+    echo "**********************************************" >> install.log
+    if [ -z $3 ] || [ -z $4 ]; then
+       cat install.log
+    fi
+    rm install.log
 else
     echo ""
     echo "Invalid subcommand: $1"
index faa3bb5..9ebe4dc 100755 (executable)
@@ -16,6 +16,11 @@ ELSE()
        SET(ARCHTYPE "\"i586\"")
        SET(ISDEVICE 0)
 ENDIF()
+IF(ASANBUILD STREQUAL true)
+       MESSAGE(STATUS "*********${BUILDTCTYPE}/${MODULE} : Building for Address Sanitizer************************************************************************")
+       SET(ASAN 1)
+       add_definitions(-DASAN=${ASAN})
+ENDIF()
 IF(DEVICE_BUILD_TYPE STREQUAL mobile)
        SET(MOBILE 1)
        add_definitions(-DMOBILE=${MOBILE})
index 3d3b8a0..529003b 100755 (executable)
 
 #include "tct_common.h"
 
+#ifdef ASAN    //Starts ASAN
+#ifdef __cplusplus
+extern "C"
+#endif
+const char *
+__asan_default_options () {
+  return "keep_going=1:malloc_context_size=2:fast_unwind_on_malloc=false:quarantine_size=32768:allow_reexec=false:start_deactivated=true:log_path=/tmp/asan_test/asan.log";
+}
+#endif  //End ASAN
 /**
 * @function            TCTCheckSystemInfoFeatureSupported
 * @description         Check the supported feature for the given key value
index a5c5a05..cff31f3 100755 (executable)
@@ -175,6 +175,9 @@ else \
 }\
 }
 
+#ifdef ASAN    //Starts ASAN 
+const char *__asan_default_options();
+#endif  //End ASAN
 bool TCTCheckSystemInfoFeatureSupported(char* pszKey, char* pszModuleName);
 char* TCTSystemInfoGetError(int nRet);
 bool GetValueFromConfigFile(char* pstrKeyString, char* pstrValue, char* pstrModule);
index 8d422dc..573f799 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index cbfa469..a75cffd 100755 (executable)
@@ -30,5 +30,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index f114a83..cdb56f5 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 69d1fb2..a55e144 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index a488e88..51e8f46 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index f0fff4f..e1106c9 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 499292e..d70c532 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 919df8a..b8a2311 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index e409142..a9aeae3 100755 (executable)
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 951c9c8..e2409f9 100755 (executable)
@@ -41,5 +41,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index ea3191e..3997d13 100755 (executable)
@@ -270,6 +270,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 5711fe2..0295421 100755 (executable)
@@ -41,5 +41,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 1a07f36..0676cc3 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 55070dc..81fcbce 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 3fa52d6..c89df73 100755 (executable)
@@ -34,5 +34,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index ad7b416..52b3c7f 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 9a056c9..63359e3 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 841dc63..0c426c8 100755 (executable)
@@ -34,5 +34,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 08c9abf..75dfbeb 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index c039ad8..e2d51f2 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 0bf13dd..b7bc2d5 100755 (executable)
@@ -37,5 +37,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 67cd712..d546397 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 96a063a..7213420 100755 (executable)
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 1d4b79c..8ee6138 100755 (executable)
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index ca3170d..b71ae54 100755 (executable)
@@ -42,5 +42,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 68e89e3..9a08310 100755 (executable)
@@ -37,5 +37,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index a870c07..3f0fc50 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index a48c801..c74dc64 100755 (executable)
@@ -45,5 +45,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 549b9d7..9ce3423 100755 (executable)
@@ -74,5 +74,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index dce538e..f4a7de5 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index ecef57a..3f52dd9 100755 (executable)
@@ -38,5 +38,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index f387580..3974ce5 100755 (executable)
@@ -39,5 +39,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 1f6b518..a931999 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 759e807..4088aa2 100755 (executable)
@@ -38,5 +38,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 1b8bd76..6da1fce 100755 (executable)
@@ -39,5 +39,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 5d72b5b..a449ae6 100755 (executable)
@@ -37,5 +37,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index c59e3d4..8299e9e 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 2c3a39e..69c64a6 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 7ab3cfc..655928d 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 0968395..1b0658f 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index eb8c789..d57595e 100755 (executable)
@@ -39,5 +39,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index e42f3fa..4419e49 100755 (executable)
@@ -45,5 +45,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 3df19ec..09c9ce8 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 7c896a1..065292e 100755 (executable)
@@ -45,5 +45,12 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+
+IF( DEFINED ASAN )
+SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
+
index dc7246f..cd496ca 100755 (executable)
@@ -195,5 +195,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 0e24eb3..ac2ddc0 100755 (executable)
@@ -88,5 +88,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
\ No newline at end of file
index 5d492ba..6e5e2f3 100755 (executable)
@@ -38,5 +38,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index fa39de3..2a3cfb7 100755 (executable)
@@ -74,5 +74,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 73b9be9..683d00d 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
-SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
\ No newline at end of file
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
\ No newline at end of file
index 740eb29..09b480b 100755 (executable)
@@ -77,5 +77,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index fa456d8..ec3fdd4 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index c6277fc..4e66b87 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 85bf290..cd14a03 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index ad23e29..ec6753b 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 2cac74e..9fdad63 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 29815be..707c7d0 100755 (executable)
@@ -32,5 +32,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
-SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall ")
+
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 342f77b..f244255 100755 (executable)
@@ -49,5 +49,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
-SET(CMAKE_C_FLAGS " -fPIE -Wall")
+
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
\ No newline at end of file
index 476f05b..827b8e6 100755 (executable)
@@ -34,5 +34,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
 
 INSTALL(FILES dfb08fe4.0 DESTINATION /etc/ssl/certs/)
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index d794b74..0a6adfd 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index e08a0ba..63f314f 100755 (executable)
@@ -32,6 +32,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 55ee171..6f696d8 100755 (executable)
@@ -37,5 +37,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index c8d4314..7cdefea 100755 (executable)
@@ -117,5 +117,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index a1346e6..a179b36 100755 (executable)
@@ -39,5 +39,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 8b6d96f..cfa15ab 100755 (executable)
@@ -36,5 +36,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 0b897c4..150233c 100755 (executable)
@@ -44,5 +44,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 1dce8c3..94cda23 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 38e6f4a..76d6f8b 100755 (executable)
@@ -38,5 +38,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 43fff60..06f0121 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 95eea63..8ef5c05 100755 (executable)
@@ -34,5 +34,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index d84c6b6..8183d35 100755 (executable)
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 91ae7cf..78e7270 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 5904bd2..3d5da27 100755 (executable)
@@ -38,5 +38,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 8536e53..d187026 100755 (executable)
@@ -38,5 +38,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 0b32506..6918a21 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 06f4633..d8b38f2 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index b42a57a..0be4934 100755 (executable)
@@ -36,5 +36,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 0911fe9..fa7ed6c 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index c3259f1..5eb4e04 100755 (executable)
@@ -34,5 +34,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
-SET(CMAKE_C_FLAGS " -fPIE -Wall")
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index ca27daa..3237076 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 5e6c97c..228cd5d 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index cf1ff28..192f381 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index f899534..ead04e2 100755 (executable)
@@ -40,6 +40,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index f07e913..1ea51db 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 884e555..f791daa 100755 (executable)
@@ -38,5 +38,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index cfadef0..db42459 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index a1dffb0..920ea47 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index c4d8ecf..c81456d 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 9b634f9..f024bc7 100755 (executable)
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index cb4c41c..113b1ae 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 993de31..90fd42f 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index a721aee..746c450 100755 (executable)
@@ -42,5 +42,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 1bbb6eb..d4e7e43 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 9b6595e..3467878 100755 (executable)
@@ -37,5 +37,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 2d880fe..e27374d 100755 (executable)
@@ -34,5 +34,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 76fa7b6..972a25b 100755 (executable)
@@ -115,5 +115,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 0db6ea4..d4fdd71 100755 (executable)
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 112261b..651034e 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index a5b99ea..38b85d3 100755 (executable)
@@ -34,5 +34,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index ecc5942..f561680 100755 (executable)
@@ -36,5 +36,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index acf4654..e407d26 100755 (executable)
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 3d89a53..6232a14 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 44f7671..03651ee 100755 (executable)
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 0448e98..5a1d5e3 100755 (executable)
@@ -34,6 +34,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 01abdba..ea0cbe6 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 3329a31..11750fb 100755 (executable)
@@ -34,5 +34,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
-SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall ")
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 494b0c8..8c4b9ec 100755 (executable)
@@ -53,5 +53,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 93c53eb..a0c07ad 100755 (executable)
@@ -52,5 +52,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 5eaf2b2..9dcd236 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index e46542c..23c604a 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index dcfdb49..96a21f4 100755 (executable)
@@ -89,5 +89,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 632a904..c7150fe 100755 (executable)
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 9028850..1a8f41d 100755 (executable)
@@ -39,5 +39,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 87d1286..3ad8f36 100755 (executable)
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 514f51a..9c5e8dc 100755 (executable)
@@ -81,5 +81,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 04ef23e..30d6de1 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index c7d527a..226e071 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_APP_FILE})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE} ${COMMON_APP_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index f706842..fdf0167 100755 (executable)
@@ -18,7 +18,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
        )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
        )
@@ -27,5 +27,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
        )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 46019da..9cbe3ce 100755 (executable)
@@ -19,7 +19,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -28,5 +28,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 0825ad7..d04f813 100755 (executable)
@@ -19,7 +19,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -28,5 +28,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 39d0aac..c8bdce4 100755 (executable)
@@ -32,7 +32,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_APP_FILE})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE} ${COMMON_APP_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -42,6 +42,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 962836e..41fb21f 100755 (executable)
@@ -23,7 +23,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
        bundle
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 9229507..ee95810 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,6 +31,12 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index f7e4e67..5c5941c 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_APP_FILE})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE} ${COMMON_APP_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index eae03e7..fdad946 100755 (executable)
@@ -34,7 +34,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -46,5 +46,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index f61a96d..936af25 100755 (executable)
@@ -109,7 +109,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -118,6 +118,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index e6fc166..af9951d 100755 (executable)
@@ -38,7 +38,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -47,6 +47,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 486d9cc..c64d958 100755 (executable)
@@ -24,7 +24,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -34,5 +34,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 58f3be1..76b5df3 100755 (executable)
@@ -35,6 +35,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 644f5a5..5a3bd2d 100755 (executable)
@@ -24,7 +24,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -33,6 +33,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 0ca0d24..097dc10 100755 (executable)
@@ -56,5 +56,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index ce9507a..6e91d3b 100755 (executable)
@@ -25,7 +25,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -39,5 +39,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 2ada427..c6edf72 100755 (executable)
@@ -43,5 +43,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index c159442..d9ec041 100755 (executable)
@@ -23,7 +23,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_APP_FILE})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE} ${COMMON_APP_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -32,6 +32,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 74018ab..5965c23 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 4e69462..180c40e 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 02d0ea2..f59cdb9 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,6 +31,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 2b63add..6d936da 100755 (executable)
@@ -115,6 +115,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
 )
 
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index dc056c8..3307c27 100755 (executable)
@@ -23,7 +23,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_APP_FILE})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE} ${COMMON_APP_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 081db06..cdebc44 100755 (executable)
@@ -26,7 +26,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
        bundle
@@ -36,5 +36,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index dbbf3bc..11c1abb 100755 (executable)
@@ -53,8 +53,14 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+SET(EXE_DALI_CORE_CTS_LINKER_FLAGS "-L${${CAPI_LIB}_LIBRARY_DIRS} -ldali-core -ldali-adaptor ")
+SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${EXE_DALI_CORE_CTS_LINKER_FLAGS}")
+ELSE()
 SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
-
 SET(EXE_DALI_CORE_CTS_LINKER_FLAGS "-L${${CAPI_LIB}_LIBRARY_DIRS} -ldali-core -ldali-adaptor ")
 SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${EXE_DALI_CORE_CTS_LINKER_FLAGS}")
+ENDIF()
index 95cc5b1..2dc3218 100755 (executable)
@@ -149,8 +149,16 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+SET(EXE_DALI_CORE_CTS_LINKER_FLAGS "-L${${CAPI_LIB}_LIBRARY_DIRS} -ldali-core -ldali-adaptor ")
+SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${EXE_DALI_CORE_CTS_LINKER_FLAGS}")
+ELSE()
 SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
-
 SET(EXE_DALI_CORE_CTS_LINKER_FLAGS "-L${${CAPI_LIB}_LIBRARY_DIRS} -ldali-core -ldali-adaptor ")
 SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${EXE_DALI_CORE_CTS_LINKER_FLAGS}")
+ENDIF()
+
+
index 157cf1f..1d1a306 100755 (executable)
@@ -96,8 +96,16 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+SET(EXE_DALI_CORE_CTS_LINKER_FLAGS "-L${${CAPI_LIB}_LIBRARY_DIRS} -ldali-core -ldali-adaptor ")
+SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${EXE_DALI_CORE_CTS_LINKER_FLAGS}")
+ELSE()
 SET(CMAKE_CXX_FLAGS " -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
-
 SET(EXE_DALI_CORE_CTS_LINKER_FLAGS "-L${${CAPI_LIB}_LIBRARY_DIRS} -ldali-core -ldali-adaptor ")
 SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${EXE_DALI_CORE_CTS_LINKER_FLAGS}")
+ENDIF()
+
+
index dc8476c..b5cc2ea 100755 (executable)
@@ -26,7 +26,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_APP_FILE})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE} ${COMMON_APP_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -37,5 +37,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall ${EXTRA_CFLAGS} -fprofile-arcs -ftest-coverage")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
+
index a60a4e2..94cac6c 100755 (executable)
@@ -33,7 +33,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -42,6 +42,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index a14fe6b..811775b 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 5e88834..31f35c5 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 9ac802c..a14c830 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 215a17b..b689ee2 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 add_definitions(-DCONFIGFILE_PATH=${CONFIGFILEPATH})
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 2cc9ae9..87904dc 100755 (executable)
@@ -25,7 +25,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -35,5 +35,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index e5d6bdb..56740ed 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
        fido-client
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 9672bc6..5d1b9e2 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index eae4483..2190234 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index c77e951..656a989 100755 (executable)
@@ -32,6 +32,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 44a991c..3efcfec 100755 (executable)
@@ -18,8 +18,13 @@ SET(TC_SOURCES
        utc-iotcon-security.c
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
 PKG_CHECK_MODULES(pkgs REQUIRED
    iotcon
index 345779e..ce2f24b 100755 (executable)
@@ -23,7 +23,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -42,5 +42,10 @@ INSTALL(FILES
     resources/p12_for_loadtest.p12
     DESTINATION /usr/share/utc_key-manager/)
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 3b8568e..24222cb 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index d5f53d1..7e57e0e 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,6 +31,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 711a998..8ef5981 100755 (executable)
@@ -23,7 +23,7 @@ INCLUDE_DIRECTORIES(
 
 SET(_FILE_OFFSET_BITS 64)
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -32,6 +32,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index ce1ecd8..bb87572 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,6 +31,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 287cbbf..c817d43 100755 (executable)
@@ -39,7 +39,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -48,6 +48,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index c6c1cd6..9feeafc 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,6 +31,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 8c52bcf..acf3a82 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 31c1bcb..9147518 100755 (executable)
@@ -31,6 +31,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index f93f59f..e01cad4 100755 (executable)
@@ -30,5 +30,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 9c5a2dc..b503791 100755 (executable)
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 6f8ee94..f274657 100755 (executable)
@@ -23,7 +23,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -32,6 +32,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 36f5ac1..be57f1b 100755 (executable)
@@ -31,6 +31,12 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
+
 
index 6c89fcb..287e5ca 100755 (executable)
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index e254c6e..56759f6 100755 (executable)
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 08de711..4340274 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index c2ab917..5b5e9a1 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
        bundle
@@ -32,5 +32,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
        DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 2d38b92..00d3c56 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     )
@@ -30,5 +30,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index eb7e5e5..080e2b1 100755 (executable)
@@ -26,7 +26,7 @@ INCLUDE_DIRECTORIES(
        system-info
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -35,6 +35,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index c5ee263..4fb95ba 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     pthread
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 887a7a4..7530483 100755 (executable)
@@ -24,7 +24,7 @@ INCLUDE_DIRECTORIES(
        system-info
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -33,6 +33,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index e0b291d..0e693ee 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,5 +29,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index b6598d5..ee9c1a2 100755 (executable)
@@ -51,7 +51,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
        bundle
@@ -61,5 +61,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index ceca72d..6ae6097 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -30,5 +30,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 7ab63d8..01058a9 100755 (executable)
@@ -64,7 +64,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_APP_FILE})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE} ${COMMON_APP_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -73,6 +73,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 733ca47..a02c1cc 100755 (executable)
@@ -26,7 +26,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -36,5 +36,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 66e60c2..7d9b2fe 100755 (executable)
@@ -40,6 +40,12 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
+
 
index 57085a7..8ecba17 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME} 
        ${${CAPI_LIB}_LIBRARIES}
        "privilege-info"
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 9cdf9a4..37d4e7a 100755 (executable)
@@ -35,6 +35,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index f7e2508..a263483 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 47ef718..9cbde11 100755 (executable)
@@ -27,7 +27,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -36,6 +36,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 87b0a05..51d3a87 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 2f63502..83427dd 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 add_definitions(-DCONFIGFILE_PATH=${CONFIGFILEPATH})
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 14470c6..50aee1d 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,5 +30,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index aeba298..10f9151 100755 (executable)
@@ -40,5 +40,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 08faf30..42aa1a2 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index aceb4f9..dbef4e1 100755 (executable)
@@ -26,7 +26,7 @@ INCLUDE_DIRECTORIES(
        system-info
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -36,5 +36,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 136c144..ce78639 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 58e77a4..f346251 100755 (executable)
@@ -26,7 +26,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -35,6 +35,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index a3bab91..6f50c13 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,5 +30,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 4a2fad4..4cda401 100755 (executable)
@@ -24,7 +24,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index e4f3c77..20eb7e6 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index a9d6181..6303c66 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
 )
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 33bfe1e..bfb8df4 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 615c21d..8922785 100755 (executable)
@@ -24,7 +24,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -33,6 +33,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index f9affd1..a50359c 100755 (executable)
@@ -31,6 +31,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index fe91b61..c795ea1 100755 (executable)
@@ -20,7 +20,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -29,6 +29,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 39d5236..64c57f8 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 409f65e..e241538 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 616e6ff..394fdce 100755 (executable)
@@ -63,7 +63,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -72,6 +72,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 3cfbdb8..59d40e5 100755 (executable)
@@ -30,6 +30,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 350d32f..af9bf61 100755 (executable)
@@ -23,7 +23,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
     bundle
@@ -33,5 +33,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index d34731d..fe5cf38 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,5 +31,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 7214c12..d4b23a2 100755 (executable)
@@ -48,7 +48,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -58,6 +58,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
 )
 
 add_definitions(-DCONFIGFILE_PATH=${CONFIGFILEPATH})
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index f0d2040..57532b8 100755 (executable)
@@ -21,7 +21,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
     glib-2.0
@@ -32,6 +32,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 196f44e..a40bf02 100755 (executable)
@@ -158,7 +158,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -167,6 +167,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index 826f8b0..20638e5 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_APP_FILE})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE} ${COMMON_APP_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -31,6 +31,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index e272a89..2296dc5 100755 (executable)
@@ -22,7 +22,7 @@ INCLUDE_DIRECTORIES(
        ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_APP_FILE})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE} ${COMMON_APP_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
        ${${CAPI_LIB}_LIBRARIES}
        bundle
@@ -32,6 +32,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
index f83e7c2..f5a9047 100755 (executable)
@@ -56,7 +56,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -65,5 +65,10 @@ INSTALL(PROGRAMS ${EXEC_NAME}
     DESTINATION ${BIN_DIR}/${RPM_NAME}/bin
 )
 
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
index 817a533..dffe835 100755 (executable)
@@ -24,7 +24,7 @@ INCLUDE_DIRECTORIES(
     ${${CAPI_LIB}_INCLUDE_DIRS}
 )
 
-ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES})
+ADD_EXECUTABLE(${EXEC_NAME} ${EXEC_NAME}.c ${TC_SOURCES} ${COMMON_FILE})
 TARGET_LINK_LIBRARIES(${EXEC_NAME}
     ${${CAPI_LIB}_LIBRARIES}
 )
@@ -34,6 +34,11 @@ INSTALL(PROGRAMS ${EXEC_NAME}
 )
 
 add_definitions(-DCONFIGFILE_PATH=${CONFIGFILEPATH})
+IF( DEFINED ASAN )
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -Wall -pie -g -fsanitize=address -fno-omit-frame-pointer")
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -Wl,-fsanitize=address")
+ELSE()
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g -fPIE -Wall")
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib -pie")
+ENDIF()
 
diff --git a/tct32_common_iot_asan.conf b/tct32_common_iot_asan.conf
new file mode 100755 (executable)
index 0000000..fb2556f
--- /dev/null
@@ -0,0 +1,30 @@
+[general]
+buildroot = ~/GBS-ROOT-TCT-COMMON_IOT-ASAN
+
+################ Profile for Device ################
+[profile.device] 
+repos = repo.public_3.0_base_arm,repo.public_3.0_common_device
+
+[repo.public_3.0_base_arm]
+url = http://download.tizen.org/snapshots/tizen/base/latest/repos/arm/packages/
+user = 
+passwd =
+
+[repo.public_3.0_common_device]
+url = http://download.tizen.org/snapshots/tizen/common/latest/repos/arm-wayland/packages/
+user = 
+passwd =
+
+################ Profile for Emulator ################
+[profile.sdk]
+repos = repo.public_3.0_base_emul,repo.public_3.0_common_emul
+
+[repo.public_3.0_base_emul]
+url = http://download.tizen.org/snapshots/tizen/base/latest/repos/emulator32/packages/
+user = 
+passwd =
+
+[repo.public_3.0_common_emul]
+url = http://download.tizen.org/snapshots/tizen/tv/latest/repos/emulator32-wayland/packages/
+user = 
+passwd = 
diff --git a/tct32_mobile_asan.conf b/tct32_mobile_asan.conf
new file mode 100755 (executable)
index 0000000..69f185e
--- /dev/null
@@ -0,0 +1,30 @@
+[general]
+buildroot = ~/GBS-ROOT-TCT-MOBILE-ASAN
+
+################ Profile for Device ################
+[profile.device] 
+repos = repo.public_3.0_base_arm,repo.public_3.0_mobile_tm1
+
+[repo.public_3.0_base_arm]
+url = http://download.tizen.org/snapshots/tizen/base/latest/repos/arm/packages/
+user = 
+passwdx = QlpoORdyRThQkAAAAAA=
+
+[repo.public_3.0_mobile_tm1]
+url = http://download.tizen.org/snapshots/tizen/mobile/latest/repos/target-TM1/packages/
+user = 
+passwdx = QlpoORdyRThQkAAAAAA=
+
+################ Profile for Emulator ################
+[profile.sdk]
+repos = repo.public_3.0_base_emul,repo.public_3.0_mobile_emul
+
+[repo.public_3.0_base_emul]
+url = http://download.tizen.org/snapshots/tizen/base/latest/repos/emulator32/packages/
+user = 
+passwdx = QlpoORdyRThQkAAAAAA=
+
+[repo.public_3.0_mobile_emul]
+url = http://download.tizen.org/snapshots/tizen/mobile/latest/repos/emulator32-wayland/packages/
+user = 
+passwdx = QlpoORdyRThQkAAAAAA=
diff --git a/tct32_tv_asan.conf b/tct32_tv_asan.conf
new file mode 100755 (executable)
index 0000000..4e07d74
--- /dev/null
@@ -0,0 +1,19 @@
+[general]
+buildroot=~/GBS-ROOT-TCT-TV-ASAN
+
+################ Profile for Device ################
+[profile.device] 
+repos = repo.public_3.0_base_arm,repo.public_3.0_tv_device,repo.public_3.0_tv_device_debug
+
+[repo.public_3.0_base_arm]
+## Product binary repository ##
+url = 
+
+[repo.public_3.0_tv_device]
+## Product binary repository ##
+url = 
+
+[repo.public_3.0_tv_device_debug]
+url = 
+
+
diff --git a/tct32_wearable_asan.conf b/tct32_wearable_asan.conf
new file mode 100755 (executable)
index 0000000..31b3a0e
--- /dev/null
@@ -0,0 +1,30 @@
+[general]
+buildroot = ~/GBS-ROOT-TCT-WEARABLE-ASAN
+
+################ Profile for Device ################
+[profile.device] 
+repos = repo.public_3.0_base_arm,repo.public_3.0_wearable_tw1
+
+[repo.public_3.0_base_arm]
+url = http://download.tizen.org/snapshots/tizen/base/latest/repos/arm/packages/
+user = 
+passwd =
+
+[repo.public_3.0_wearable_tw1]
+url = http://download.tizen.org/snapshots/tizen/wearable/latest/repos/target-circle/packages/
+user = 
+passwd =
+
+################ Profile for Emulator ################
+[profile.sdk]
+repos = repo.public_3.0_base_emul,repo.public_3.0_wearable_emul
+
+[repo.public_3.0_base_emul]
+url = http://download.tizen.org/snapshots/tizen/base/latest/repos/emulator32/packages/
+user = 
+passwd =
+
+[repo.public_3.0_wearable_emul]
+url = http://download.tizen.org/snapshots/tizen/wearable/latest/repos/emulator32-wayland/packages/
+user = 
+passwd =
diff --git a/tct64_common_iot_asan.conf b/tct64_common_iot_asan.conf
new file mode 100755 (executable)
index 0000000..18622aa
--- /dev/null
@@ -0,0 +1,18 @@
+[general]
+buildroot = ~/GBS-ROOT-TCT-COMMON_IOT-ASAN
+
+[profile.device] # Profile for Device
+obs = obs.device
+repos =
+
+[profile.sdk]   # Profile for SDK
+obs = obs.sdk
+repos =
+
+[obs.device]   # obs for SDK.Ref_Target
+#OBS API URL pointing to a remote OBS.
+url = https://168.219.209.58/
+
+[obs.sdk]              # obs for SDK.Emulator
+#OBS API URL pointing to a remote OBS.
+url =
diff --git a/tct64_mobile_asan.conf b/tct64_mobile_asan.conf
new file mode 100755 (executable)
index 0000000..be35155
--- /dev/null
@@ -0,0 +1,38 @@
+[general]
+buildroot = ~/GBS-ROOT-TCT-MOBILE-ASAN
+
+[profile.device] # Profile for Device
+obs = obs.device
+repos = repo.public_3.0_base_arm64,repo.public_3.0_mobile_arm64
+
+[profile.sdk]   # Profile for SDK
+obs = obs.sdk
+repos = repo.public_3.0_base_emul,repo.sdk
+
+[obs.device]   # obs for SDK.Ref_Target
+#OBS API URL pointing to a remote OBS.
+url = https://168.219.209.58/
+
+[obs.sdk]              # obs for SDK.Emulator
+#OBS API URL pointing to a remote OBS.
+url = https://168.219.209.58/
+
+[repo.public_3.0_base_arm64]
+url = http://download.tizen.org/snapshots/tizen/mobile/latest/repos/arm64-wayland/packages/
+user = 
+passwd = 
+
+[repo.public_3.0_mobile_arm64]
+url = http://download.tizen.org/snapshots/tizen/mobile/latest/repos/arm64-wayland/packages/
+user = 
+passwd = 
+
+[repo.public_3.0_base_emul]
+url = http://165.213.149.200/download/public_mirror/tizen/base/latest/repos/emulator64/packages/
+user = 
+passwd = 
+
+[repo.sdk]
+url = http://165.213.149.200/download/public_mirror/tizen/mobile/latest/repos/emulator64-wayland/packages/
+user = 
+passwd = 
diff --git a/tct64_tv_asan.conf b/tct64_tv_asan.conf
new file mode 100755 (executable)
index 0000000..3f4c82c
--- /dev/null
@@ -0,0 +1,15 @@
+[general]
+buildroot=~/GBS-ROOT-TCT-TV-ASAN
+
+[profile.device] # Profile for Device
+obs=obs.device
+repos = repo.public_3.0_base_arm,repo.public_3.0_tv_arm
+
+[obs.device]
+url = https://168.219.209.58/
+
+[repo.public_3.0_base_arm]
+url = 
+
+[repo.public_3.0_tv_arm]
+url =
diff --git a/tct64_wearable_asan.conf b/tct64_wearable_asan.conf
new file mode 100755 (executable)
index 0000000..c0353da
--- /dev/null
@@ -0,0 +1,30 @@
+[general]
+buildroot = ~/GBS-ROOT-TCT-WEARABLE-ASAN
+
+[profile.device] # Profile for Device
+obs = obs.device
+repos = repo.public_3.0_base_arm64,repo.public_3.0_mobile_arm64
+
+[profile.sdk]   # Profile for SDK
+obs = obs.sdk
+repos = repo.public_3.0_base_emulator64,repo.public_3.0_mobile_emulator64
+
+[obs.device]   # obs for SDK.Ref_Target
+#OBS API URL pointing to a remote OBS.
+url = https://168.219.209.58/
+
+[obs.sdk]              # obs for SDK.Emulator
+#OBS API URL pointing to a remote OBS.
+url = https://168.219.209.58/
+
+[repo.public_3.0_base_arm64]
+url = http://download.tizen.org/snapshots/tizen/mobile/latest/repos/arm64-wayland/packages/
+
+[repo.public_3.0_base_emulator64]
+url = http://download.tizen.org/snapshots/tizen/base/latest/repos/emulator64/packages/
+
+[repo.public_3.0_mobile_arm64]
+url = http://download.tizen.org/snapshots/tizen/mobile/latest/repos/arm64-wayland/packages/
+
+[repo.public_3.0_mobile_emulator64]
+url = http://download.tizen.org/snapshots/tizen/mobile/latest/repos/emulator64-wayland/packages/
diff --git a/templates/external_wrapper_asan/external_wrapper.sh b/templates/external_wrapper_asan/external_wrapper.sh
new file mode 100755 (executable)
index 0000000..5ce7e97
--- /dev/null
@@ -0,0 +1,190 @@
+
+
+#!/bin/bash
+#
+# Copyright (c) 2014 Samsung Electronics Co., Ltd.
+#
+# Licensed under the Apache License, Version 2.0 (the License);
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http:#www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+############ address sanitizer ######################
+ASAN_DIR=/tmp/asan_test
+mkdir -p $ASAN_DIR
+chmod 777 $ASAN_DIR -R
+chsmack -a "*" $ASAN_DIR
+rm -f $ASAN_DIR/asan.log.*
+######################################################
+
+
+TIMEOUT_VALUE=60 #default timeout value
+FILE="/tmp/TC_Timeout.txt"
+
+UTC_LOG_CORE=/tmp/utclog_core
+
+if [[ "$1" == "" || "$2" == "" || "$3" == "" ]];
+then
+    echo "module name, TC name and build type type needed"
+    exit 1
+fi
+
+#Read timeout value from /tmp/TCT_Timeout.txt file
+
+if [ -f $FILE ];
+then
+       for next in `cat $FILE`
+       do
+           TIMEOUT_VALUE=$next
+       done
+fi
+
+
+function Execute {
+       RESULT_PATH=/tmp/tcresult
+       ERRLOG_PATH=/tmp/tclog
+       rm -f $RESULT_PATH
+       rm -f $ERRLOG_PATH
+       rm -f $UTC_LOG_CORE
+       
+       RET=`su -c "app_launcher -e native.$1-$3 testcase_name $2" owner`
+       if [[ $RET == *"successfully launched"* ]];then
+               echo "Successfully Launched"
+       else
+               echo "Launch Failed"
+               su -c "app_launcher -t native.$1-$3 > /dev/null" owner
+               exit 1
+       fi
+
+       COUNTER=0
+       while [ ! -e $RESULT_PATH ];
+       do
+               if [ $COUNTER -eq $TIMEOUT_VALUE ];
+               then
+                       # terminate launched application
+                       su -c "app_launcher -t native.$1-$3 > /dev/null" owner
+                       echo "Timeout! [ Execution exceeded $TIMEOUT_VALUE seconds ]"
+                       if [ -e $ERRLOG_PATH ];
+                       then
+                               echo `cat $ERRLOG_PATH`
+                               rm -f $ERRLOG_PATH
+                       fi
+                       ############################## address sanitizer ############################
+                       echo "\n\n======================= Address Sanitizer Info ======================="
+                       ASAN_RESULT=`ls /tmp/asan_test`
+                       if [[ $ASAN_RESULT == "" ]];then
+                               echo "ASAN Did Not Find Any Memory Corruption Issue During Execution"
+                       else
+                               cat $ASAN_DIR/$ASAN_RESULT
+                       fi
+                       echo "================================================================"
+                       #############################################################################
+                       exit 1
+               fi
+               sleep 1
+               COUNTER=$(($COUNTER + 1))
+       done
+
+       if [ -e $ERRLOG_PATH ];
+       then
+               echo `cat $ERRLOG_PATH`
+               rm -f $ERRLOG_PATH
+       fi
+       if [ -e $UTC_LOG_CORE ];
+       then
+               echo `cat $UTC_LOG_CORE`
+               rm -f $UTC_LOG_CORE
+       fi
+       ############################## address sanitizer ############################
+       echo "\n\n======================= Address Sanitizer Info ======================="
+       ASAN_RESULT=`ls /tmp/asan_test`
+       if [[ $ASAN_RESULT == "" ]];then
+               echo "ASAN Did Not Find Any Memory Corruption Issue During Execution"
+       else
+               cat $ASAN_DIR/$ASAN_RESULT
+       fi
+       echo "================================================================"
+       #############################################################################
+       exit `cat $RESULT_PATH`
+}
+
+function ExecuteUTC {
+       RESULT_PATH=/tmp/tcresult
+       ERRLOG_PATH=/tmp/utclog
+       rm -f $RESULT_PATH
+       rm -f $ERRLOG_PATH
+       rm -f $UTC_LOG_CORE
+       RET=`su -c "app_launcher -e core.$1-tests testcase_name $2" owner`
+       if [[ $RET == *"successfully launched"* ]];then
+               echo "Successfully Launched"
+       else
+               echo "Launch Failed"
+               su -c "app_launcher -t core.$1-tests > /dev/null" owner
+               exit 1
+       fi
+       COUNTER=0
+       while [ ! -e $RESULT_PATH ];
+       do
+               if [ $COUNTER -eq $TIMEOUT_VALUE ];
+               then
+                       # terminate launched application
+                       su -c "app_launcher -t core.$1-tests > /dev/null" owner
+                       echo "Timeout! [ Execution exceeded $TIMEOUT_VALUE seconds ]"
+
+                       ############################## address sanitizer ############################
+                       echo "\n\n======================= Address Sanitizer Info ======================="
+                       ASAN_RESULT=`ls /tmp/asan_test`
+                       if [[ $ASAN_RESULT == "" ]];then
+                               echo "ASAN Did Not Find Any Memory Corruption Issue During Execution"
+                       else
+                               cat $ASAN_DIR/$ASAN_RESULT
+                       fi
+                       echo "================================================================"
+                       #############################################################################
+                       exit 1
+               fi
+               sleep 1
+               COUNTER=$(($COUNTER + 1))
+       done
+       if [ -e $ERRLOG_PATH ];
+       then
+               echo `cat $ERRLOG_PATH`
+               rm -f $ERRLOG_PATH
+       fi
+       if [ -e $UTC_LOG_CORE ];
+       then
+               echo `cat $UTC_LOG_CORE`
+               rm -f $UTC_LOG_CORE
+       fi
+       ############################## address sanitizer ############################
+       echo "\n\n======================= Address Sanitizer Info ======================="
+       ASAN_RESULT=`ls /tmp/asan_test`
+       if [[ $ASAN_RESULT == "" ]];then
+               echo "ASAN Did Not Find Any Memory Corruption Issue During Execution"
+       else
+               cat $ASAN_DIR/$ASAN_RESULT
+       fi
+       echo "================================================================"
+       #############################################################################
+       exit `cat $RESULT_PATH`
+}
+
+if [[ $3 == "itc" ]] || [[ $3 == "ctc" ]] ;then
+       Execute $1 $2 $3
+else
+       ExecuteUTC $1 $2
+fi
+
+
+
+
+
+
diff --git a/templates/tct-package-asan/inst.sh b/templates/tct-package-asan/inst.sh
new file mode 100755 (executable)
index 0000000..7abb3a2
--- /dev/null
@@ -0,0 +1,167 @@
+#!/bin/bash
+#
+# Copyright (c) 2014 Samsung Electronics Co., Ltd.
+#
+# Licensed under the Apache License, Version 2.0 (the License);
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http:#www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+NAME=$(basename $(cd $(dirname $0);pwd))
+MOD_NAME=%{MOD_NAME}
+PKG_DIR=%{PKG_DIR} # directory supplied by external script
+PKG_NAME=%{PKG_NAME} # name supplied by external script
+PKG_FULLNAME=%{PKG_FULLNAME} # name supplied by external script
+APP_DIR=/usr/apps
+
+#parse params
+USAGE="Usage: ./inst.sh [-i] [-u]
+  -i install wgt and config environment
+  -u uninstall wgt and remove source file
+[-i] option was set as default."
+
+# extract TCT configuration directory from TCT_CONFIG_FILE (/opt/tools/TCT_CONFIG)
+TCT_CONFIG_FILE=/tmp/TCT_CONFIG
+if [ ! -f $TCT_CONFIG_FILE ];then
+       echo ""
+       echo "****************FATAL ERROR : $PKG_DIR/inst.sh***************************"
+       echo "$TCT_CONFIG_FILE is not Found : Can Not Read TCT Configuration Directory"
+       echo "$PKG_NAME : INSTALLATION/UNINSTALLATION Can Not Proceed"
+       echo "********************************************************************"
+       echo ""
+       return;
+fi
+DEVICE_SUITE_TARGET_30=`cat $TCT_CONFIG_FILE | grep DEVICE_SUITE_TARGET_30 | cut -f 2- -d '='`
+if [ $DEVICE_SUITE_TARGET_30 == "" ]; then
+       echo ""
+       echo "****************FATAL ERROR : $PKG_DIR/inst.sh***************************"
+       echo "$TCT_CONFIG_FILE is not Found : Can Not Read TCT Configuration Directory"
+       echo "$PKG_NAME : INSTALLATION/UNINSTALLATION Can Not Proceed"
+       echo "********************************************************************"
+       echo ""
+       return;
+fi
+DEVICE_USER_30=`cat $TCT_CONFIG_FILE | grep DEVICE_USER_30 | cut -f 2- -d '='`
+if [ $DEVICE_USER_30 == "" ]; then
+       echo ""
+       echo "****************FATAL ERROR : $PKG_DIR/inst.sh***************************"
+       echo "$TCT_CONFIG_FILE is not Found : Can Not Read TCT Configuration Directory"
+       echo "$PKG_NAME : INSTALLATION/UNINSTALLATION Can Not Proceed"
+       echo "********************************************************************"
+       echo ""
+       return;
+fi
+
+if [[ $PKG_NAME == *"-itc" ]] ;then
+       SUITENAME=$MOD_NAME-native
+       APP_ID=native.${PKG_NAME#native-}
+       EXE_SUFFIX="native"
+elif [[ $PKG_NAME == *"-ctc" ]]; then
+       SUITENAME=$MOD_NAME-ctc
+       APP_ID=native.${PKG_NAME#native-}
+       EXE_SUFFIX="ctc"
+else
+       SUITENAME=$MOD_NAME-core
+       APP_ID=core.${PKG_NAME#core-}
+       EXE_SUFFIX="core"
+fi
+
+function installpkg(){
+    if [ `date +%Y` -lt 2015 ]
+    then
+        date -s "1 JUL 2015 00:00:00"
+    fi
+
+    if [ ! -d $DEVICE_SUITE_TARGET_30/res/ ]; then
+        mkdir $DEVICE_SUITE_TARGET_30/res
+    fi
+    cp -rf $PKG_DIR/res $DEVICE_SUITE_TARGET_30/
+    find $DEVICE_SUITE_TARGET_30/res/ -exec chsmack -a "User::App::Shared" {} \;
+    rpm -e `rpm -qa | grep $PKG_NAME`
+    rpm -ih $PKG_DIR/$PKG_FULLNAME
+   # pkginfo --imd /usr/share/packages/$PKG_NAME\.xml
+   # pkg_privilege -i /usr/share/packages/$PKG_NAME\.xml
+    tpk-backend --preload -y $PKG_NAME
+    mkdir -p $DEVICE_USER_30/apps_rw/$PKG_NAME/data
+    if [ -d $APP_DIR/$PKG_NAME/data ]; then
+        cp -a $APP_DIR/$PKG_NAME/data/* $DEVICE_USER_30/apps_rw/$PKG_NAME/data/
+    fi
+    chown -R owner:users $DEVICE_USER_30/apps_rw/$PKG_NAME/
+    chsmack -a "User::App::$APP_ID" $DEVICE_USER_30/apps_rw/$PKG_NAME
+    chsmack -a "User::App::$APP_ID" $DEVICE_USER_30/apps_rw/$PKG_NAME/data
+    su -c "aul_test reload" owner
+
+    ###################### address sanitizer #########################
+    echo "User::App::$APP_ID System rwx" | smackload
+    if [ -f $PKG_DIR/tct-$MOD_NAME-$EXE_SUFFIX ]; then
+       cp $PKG_DIR/tct-$MOD_NAME-$EXE_SUFFIX /usr/apps/$PKG_NAME/bin/
+    fi
+    ##################################################################
+
+    cp $PKG_DIR/external_wrapper.sh $DEVICE_SUITE_TARGET_30/
+
+    if [ "$(echo $HOSTTYPE)" == "armv7l" ]; then
+           applist=`ls $DEVICE_SUITE_TARGET_30/res | grep tpk | grep arm`
+    elif [ "$(echo $HOSTTYPE)" == "aarch64" ]; then
+           applist=`ls $DEVICE_SUITE_TARGET_30/res | grep tpk | grep aarch64`
+    else
+           applist=`ls $DEVICE_SUITE_TARGET_30/res | grep tpk | grep i386`
+    fi
+
+    for app in $applist
+    do
+        su -c "pkgcmd -iqt tpk -p $DEVICE_SUITE_TARGET_30/res/$app > /dev/null" owner
+    done
+
+    if [[ $PKG_NAME == *"application"* || $PKG_NAME == *"message-port"* ]]; then
+           ( echo 3 ; sleep 1 ; echo MIIClTCCAX2gAwIBAgIGAU1wuKP1MA0GCSqGSIb3DQEBBQUAMFYxGjAYBgNVBAoMEVRpemVuIEFzc29jaWF0aW9uMRowGAYDVQQLDBFUaXplbiBBc3NvY2lhdGlvbjEcMBoGA1UEAwwTVGl6ZW4gRGV2ZWxvcGVycyBDQTAeFw0xMjExMDEwMDAwMDBaFw0xOTAxMDEwMDAwMDBaMBExDzANBgNVBAMMBmF1dGhvcjCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAkzTMc+oxDLzYKi7TWoN8vMeMwLTdjxECyrdrv/8SJmqzvV4fYVUKx7kdRHCHazb1BGDxtgt4Ntilc+Qt5a42BNi19HTDpoWuga1fL7U3B/UNRmWjarHQQOLKcQ+2QD4vMjVpf4UOe8zE9ssCTKDNEw5ELV6XVwWoP9GYIXMug2UCAwEAAaMyMDAwDAYDVR0TAQH/BAIwADALBgNVHQ8EBAMCB4AwEwYDVR0lBAwwCgYIKwYBBQUHAwMwDQYJKoZIhvcNAQEFBQADggEBAMj0yAvusFduH+ABua+EijUBRzfhy68WaXOB7i4KfBYeQtJx5zeu0M5tttpaAibLF7MVrazaV2B6Q8IlI8WA13USwhPOeIlcOUX0zmw7TYCJtfuDf3ybKaxIMgWLFUt2Gcb2r/MT6kT49LdLOhKkfkonxSZflmcLEJNIb/K8/n6ERimFsO2L0tI2Eqh6YNUpyNxLsJEkZm6DDeOvW0yZXqDNoymAwmG9bg7x2gA6i/E7e3UjODvWxmLfS6qvNkDs21OSTLjspvzjWPFkTdJx2DJu88xGHO7IUYUk6e8UPtzvVR/0J2JY1d9znMmYVdax/HBG0E7875UFMTlwZ/Yhxc0= ; sleep 1 ; echo 0 ) | pkginfo --setcert $PKG_NAME
+    fi
+
+    if [ -d $DEVICE_USER_30/apps_rw/org.tizen.messageportapp ]; then
+           ( echo 3 ; sleep 1 ; echo MIIClTCCAX2gAwIBAgIGAU1wuKP1MA0GCSqGSIb3DQEBBQUAMFYxGjAYBgNVBAoMEVRpemVuIEFzc29jaWF0aW9uMRowGAYDVQQLDBFUaXplbiBBc3NvY2lhdGlvbjEcMBoGA1UEAwwTVGl6ZW4gRGV2ZWxvcGVycyBDQTAeFw0xMjExMDEwMDAwMDBaFw0xOTAxMDEwMDAwMDBaMBExDzANBgNVBAMMBmF1dGhvcjCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAkzTMc+oxDLzYKi7TWoN8vMeMwLTdjxECyrdrv/8SJmqzvV4fYVUKx7kdRHCHazb1BGDxtgt4Ntilc+Qt5a42BNi19HTDpoWuga1fL7U3B/UNRmWjarHQQOLKcQ+2QD4vMjVpf4UOe8zE9ssCTKDNEw5ELV6XVwWoP9GYIXMug2UCAwEAAaMyMDAwDAYDVR0TAQH/BAIwADALBgNVHQ8EBAMCB4AwEwYDVR0lBAwwCgYIKwYBBQUHAwMwDQYJKoZIhvcNAQEFBQADggEBAMj0yAvusFduH+ABua+EijUBRzfhy68WaXOB7i4KfBYeQtJx5zeu0M5tttpaAibLF7MVrazaV2B6Q8IlI8WA13USwhPOeIlcOUX0zmw7TYCJtfuDf3ybKaxIMgWLFUt2Gcb2r/MT6kT49LdLOhKkfkonxSZflmcLEJNIb/K8/n6ERimFsO2L0tI2Eqh6YNUpyNxLsJEkZm6DDeOvW0yZXqDNoymAwmG9bg7x2gA6i/E7e3UjODvWxmLfS6qvNkDs21OSTLjspvzjWPFkTdJx2DJu88xGHO7IUYUk6e8UPtzvVR/0J2JY1d9znMmYVdax/HBG0E7875UFMTlwZ/Yhxc0= ; sleep 1 ; echo 0 ) | su -c "pkginfo --setcert org.tizen.messageportapp" owner
+    fi
+}
+
+function uninstallpkg(){
+### remove source file ###
+
+# terminate launched application
+su -c "app_launcher -t $APP_ID > /dev/null" owner
+
+if [ -d $DEVICE_SUITE_TARGET_30/tct/opt/$NAME ];then
+    rm -rf $DEVICE_SUITE_TARGET_30/tct/opt/$NAME
+    tpk-backend -d $PKG_NAME --preload --force-remove
+    rpm -e `rpm -qa | grep $PKG_NAME`
+    su -c "aul_test reload" owner
+    if [ -d $DEVICE_SUITE_TARGET_30/Images/test ];then
+        rm -rf $DEVICE_SUITE_TARGET_30/Images/test*
+    fi
+else
+    echo "Remove source file fail, please check if the source file exist: $DEVICE_SUITE_TARGET_30/tct/opt/$NAME ..."
+fi
+    applist=`ls $DEVICE_SUITE_TARGET_30/res | grep tpk | awk -F'-' '{print $1}'`
+    for app in $applist
+    do
+       su -c "pkgcmd -u -n $app > /dev/null" owner
+
+    done
+    rm -rf $DEVICE_SUITE_TARGET_30/res
+}
+
+case "$1" in
+    -h|--help) echo "$USAGE"
+               exit ;;
+    ""|-i) installpkg $2;;
+    -u) uninstallpkg;;
+    *) echo "Unknown option: $1"
+       echo "$USAGE"
+       exit ;;
+esac