USE PORTABLE to avoid Illegal instruction, add SANITIZE for rocksdb cmake build

options
This commit is contained in:
sundy-li 2020-10-02 10:26:59 +08:00
parent 1f4a63b6c6
commit 99cfb8aa2b

View File

@ -323,6 +323,17 @@ if (USE_INTERNAL_ROCKSDB_LIBRARY)
set(WITH_TESTS OFF)
set(WITH_BENCHMARK_TOOLS OFF)
set(WITH_TOOLS OFF)
set (WITH_GFLAGS OFF)
set(WITH_GFLAGS OFF)
set(PORTABLE ON)
set(FORCE_SSE42 ON)
if (SANITIZE STREQUAL "undefined")
set(WITH_UBSAN ON)
elseif (SANITIZE STREQUAL "address")
set(WITH_ASAN ON)
elseif (SANITIZE STREQUAL "thread")
set(WITH_TSAN ON)
endif()
add_subdirectory (rocksdb)
endif()