mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-25 12:38:48 +03:00
Add compile option for address sanitizers
This commit is contained in:
parent
156e1e62a6
commit
b47007d59a
1 changed files with 5 additions and 0 deletions
|
@ -1,6 +1,7 @@
|
|||
cmake_minimum_required(VERSION 3.1)
|
||||
|
||||
option(APPVEYOR_BUILD "Build on appveyor" OFF)
|
||||
option(ASAN "Compile with address sanitizers" OFF)
|
||||
|
||||
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
|
||||
|
||||
|
@ -311,6 +312,10 @@ set(NHEKO_DEPS
|
|||
${TRANSLATION_DEPS}
|
||||
${META_FILES_TO_INCLUDE})
|
||||
|
||||
if(ASAN)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address,undefined")
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
||||
add_executable (nheko ${OS_BUNDLE} ${NHEKO_DEPS})
|
||||
target_link_libraries (nheko ${NHEKO_LIBS} Qt5::MacExtras Qt5::Multimedia)
|
||||
|
|
Loading…
Reference in a new issue