mirror of
https://github.com/pybind/pybind11.git
synced 2026-04-27 18:21:30 +00:00
fix: using -Werror-all for Intel (#2948)
* correcting Werror for Intel * adding ward for Intel * adding wards for intel * another ward for Intel * missed one intel ward * exact match for intel compiler * removing inline limits * disable warnings about inline limits * formatter suggestion * more indent * hopefully make formatter happy * addressed review * fix && * Update tests/CMakeLists.txt Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com> Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com>
This commit is contained in:
@@ -268,8 +268,15 @@ function(pybind11_enable_warnings target_name)
|
||||
target_compile_options(${target_name} PRIVATE /WX)
|
||||
elseif(PYBIND11_CUDA_TESTS)
|
||||
target_compile_options(${target_name} PRIVATE "SHELL:-Werror all-warnings")
|
||||
elseif(CMAKE_CXX_COMPILER_ID MATCHES "(GNU|Intel|Clang)")
|
||||
elseif(CMAKE_CXX_COMPILER_ID MATCHES "(GNU|Clang|IntelLLVM)")
|
||||
target_compile_options(${target_name} PRIVATE -Werror)
|
||||
elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Intel")
|
||||
target_compile_options(
|
||||
${target_name}
|
||||
PRIVATE
|
||||
-Werror-all
|
||||
# "Inlining inhibited by limit max-size", "Inlining inhibited by limit max-total-size"
|
||||
-diag-disable 11074,11076)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user