[Tarantool-patches] [PATCH v2 03/10] cmake: add option ENABLE_UB_SANITIZER

Vladislav Shpilevoy v.shpilevoy at tarantool.org
Sat May 30 01:36:19 MSK 2020


Hi! Thanks for the comment!

On 29/05/2020 10:53, Sergey Bronnikov wrote:
> Vlad,
> 
> thanks for the patch!
> 
> On 01:32 Thu 28 May , Vladislav Shpilevoy wrote:
> 
> <snipped>
> 
>> diff --git a/cmake/compiler.cmake b/cmake/compiler.cmake
>> index ce3e7e506..373bcd3b0 100644
>> --- a/cmake/compiler.cmake
>> +++ b/cmake/compiler.cmake
>> @@ -238,6 +238,8 @@ endif()
>>  
>>  option(ENABLE_WERROR "Make all compiler warnings into errors" OFF)
>>  
>> +option(ENABLE_UB_SANITIZER "Make the compiler generate runtime code to perform undefined behaviour checks" OFF)
> 
> It would be useful to add ENABLE_UB_SANITIZER option to a list "options"
> in a root CMakeLists.txt. cmake shows options from this list and it's
> status at the end of output.

I didn't even know that the option list existed, nice. Added:

====================
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 1d80b6806..e49317f8a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -571,7 +571,7 @@ set(PREFIX ${CMAKE_INSTALL_PREFIX})
 set(options PACKAGE VERSION BUILD C_COMPILER CXX_COMPILER C_FLAGS CXX_FLAGS
     PREFIX
     ENABLE_SSE2 ENABLE_AVX
-    ENABLE_GCOV ENABLE_GPROF ENABLE_VALGRIND ENABLE_ASAN
+    ENABLE_GCOV ENABLE_GPROF ENABLE_VALGRIND ENABLE_ASAN ENABLE_UB_SANITIZER
     ENABLE_BACKTRACE
     ENABLE_DOC
     ENABLE_DIST


More information about the Tarantool-patches mailing list