summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVyacheslav Cherkashin <v.cherkashin@samsung.com>2019-07-19 15:05:47 +0300
committerVyacheslav Cherkashin <v.cherkashin@samsung.com>2019-07-29 17:33:50 +0300
commitd6c5fd363ef8aa14820bf2e1db517392ef8a37e8 (patch)
tree7a1b09cc6757b55fd8ccd9bd588bf9aa9d971028
parent03a5f45c5c680c2e3505847806e18f4f877d3be2 (diff)
downloadcoreclr-d6c5fd363ef8aa14820bf2e1db517392ef8a37e8.tar.gz
coreclr-d6c5fd363ef8aa14820bf2e1db517392ef8a37e8.tar.bz2
coreclr-d6c5fd363ef8aa14820bf2e1db517392ef8a37e8.zip
[Tizen] Enable Tizen ASan runtime supportsandbox/ches01/asan_ARM
Enable libasansi.so support (libasan.so with switchable interceptors). Change-Id: I9ee9b47b7beab55f036ffc0697ffab2583e9701c Signed-off-by: Vyacheslav Cherkashin <v.cherkashin@samsung.com>
-rw-r--r--configurecompiler.cmake7
-rwxr-xr-xpackaging/coreclr.spec4
2 files changed, 10 insertions, 1 deletions
diff --git a/configurecompiler.cmake b/configurecompiler.cmake
index 803e6e4e3b..8537f80002 100644
--- a/configurecompiler.cmake
+++ b/configurecompiler.cmake
@@ -277,6 +277,13 @@ elseif (CLR_CMAKE_PLATFORM_UNIX)
message(FATAL_ERROR "Unknown build type! Set CMAKE_BUILD_TYPE to DEBUG, CHECKED, RELEASE, or RELWITHDEBINFO!")
endif ()
+ if(DEFINED ENV{TIZEN_ASAN_ENVIRONMENT})
+ message(STATUS "Enable TIZEN_ASAN_ENVIRONMENT")
+ # add definitions to enable ASan support for only external libraries (supported only Tizen)
+ add_definitions(-DTIZEN_ASAN_ENVIRONMENT -DHAS_ADDRESS_SANITIZER)
+ set(TIZEN_ASAN_ENVIRONMENT 1)
+ endif()
+
# set the CLANG sanitizer flags for debug build
if(UPPERCASE_CMAKE_BUILD_TYPE STREQUAL DEBUG OR UPPERCASE_CMAKE_BUILD_TYPE STREQUAL CHECKED)
# obtain settings from running enablesanitizers.sh
diff --git a/packaging/coreclr.spec b/packaging/coreclr.spec
index 5de40d1251..981d610441 100755
--- a/packaging/coreclr.spec
+++ b/packaging/coreclr.spec
@@ -148,7 +148,9 @@ done
export ASAN_OPTIONS=use_sigaltstack=false:`cat /ASAN_OPTIONS`
/usr/bin/gcc-unforce-options
export LD_LIBRARY_PATH=`pwd`/libicu-57.1
-export CPPFLAGS+=" -DHAS_ADDRESS_SANITIZER "
+
+# enable ASan support for only external libs
+export TIZEN_ASAN_ENVIRONMENT=1
}
export CFLAGS=" --target=%{_host} "