SWDEV-429802 - change address sanitizer variable name to ENABLE_ADDRESS_SANITIZER
This is to bring scripts in compute/ec/prototype in sync which uses this particular variable to enable address sanitizer across projects. Change-Id: Ia620e4fd86338554ee3dd57c5690edb919b6e5a5
Cette révision appartient à :
révisé par
Jatin Jaikishan Chaudhary
Parent
252fca5aa8
révision
508991225f
+1
-1
@@ -59,4 +59,4 @@ hipcc $HIP_TESTS_DIR/catch/unit/memory/hipPointerGetAttributes.cc -I ./catch/inc
|
||||
|
||||
### Building with address sanitizer
|
||||
|
||||
To build catch tests with Address Sanitizer options, use the cmake option `-DASAN_BUILD=ON`
|
||||
To build catch tests with Address Sanitizer options, use the cmake option `-DENABLE_ADDRESS_SANITIZER=ON`
|
||||
|
||||
@@ -6,7 +6,7 @@ set(CMAKE_CXX_COMPILER_WORKS 1)
|
||||
|
||||
project(hiptests)
|
||||
|
||||
option(ASAN_BUILD "Option to enable ASAN build" OFF)
|
||||
option(ENABLE_ADDRESS_SANITIZER "Option to enable ASAN build" OFF)
|
||||
|
||||
# flag to generate standalone exe per src file.
|
||||
message(STATUS "STANDALONE_TESTS : ${STANDALONE_TESTS}")
|
||||
@@ -68,7 +68,7 @@ execute_process(COMMAND ${HIPCONFIG_EXECUTABLE} --version
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --std=c++17")
|
||||
|
||||
# Address sanitizer options
|
||||
if(ASAN_BUILD)
|
||||
if(ENABLE_ADDRESS_SANITIZER)
|
||||
message(STATUS "Building catch tests with Address Sanitizer options")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=address -shared-libasan -g -gz")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address -shared-libasan -g -gz")
|
||||
|
||||
Référencer dans un nouveau ticket
Bloquer un utilisateur