Глобальные настройки PVS-Studio
This commit is contained in:
parent
186d67c4bb
commit
2be896c4a8
@ -15,6 +15,12 @@ function(add_pvs_check target)
|
||||
ARGS --analysis-mode 29 --exclude-path ${CMAKE_CURRENT_BINARY_DIR}/${target}_autogen
|
||||
MODE GA:1,2,3;64:1;OP:1,2;CS:1,2)
|
||||
add_dependencies(pvs-check pvs-check-${target})
|
||||
configure_file("${CMLIB_MODULE_DIR}/hpp/pvs_studio.hpp.in" "${CMAKE_BINARY_DIR}/include/pvs_studio.hpp")
|
||||
if(MSVC)
|
||||
target_compile_options(${target} PRIVATE /FI "${CMAKE_BINARY_DIR}/include/pvs_studio.hpp")
|
||||
else() # GCC/Clang
|
||||
target_compile_options(${target} PRIVATE -include "${CMAKE_BINARY_DIR}/include/pvs_studio.hpp")
|
||||
endif()
|
||||
else()
|
||||
message(STATUS "CMLIB warning:")
|
||||
message(STATUS " PVS-Studio analyzer is not found")
|
||||
|
8
hpp/pvs_studio.hpp.in
Normal file
8
hpp/pvs_studio.hpp.in
Normal file
@ -0,0 +1,8 @@
|
||||
#ifndef PVS_STUDIO_HPP_
|
||||
#define PVS_STUDIO_HPP_
|
||||
|
||||
#pragma once
|
||||
|
||||
//-V813_MINSIZE=33
|
||||
|
||||
#endif // PVS_STUDIO_HPP_
|
Loading…
Reference in New Issue
Block a user