Правка для поиска pvs-studio

This commit is contained in:
Andrei Astafev 2021-12-21 14:44:43 +03:00
parent 5d7824ebdd
commit 396e2f38f9

View File

@ -1,11 +1,13 @@
if(CMAKE_EXPORT_COMPILE_COMMANDS)
include(PVS-Studio)
find_program(PVS_STUDIO_ANALYZER_EXE pvs-studio-analyzer)
find_program(PVS_STUDIO_CONVERTER_EXE plog-converter)
else()
message(STATUS "MyxCMake: CMAKE_EXPORT_COMPILE_COMMANDS is not set. PVS checks will be disabled.")
endif()
function(myx_cmake_analyze_pvs_studio target)
if(EXISTS PVS_STUDIO_BIN_PATH AND EXISTS PVS_STUDIO_CONVERTER_PATH)
if(PVS_STUDIO_ANALYZER_EXE AND PVS_STUDIO_CONVERTER_EXE)
set(options)
set(oneValueArgs CHECKS)
set(multiValueArgs)