Skip to content

Commit ea6fe71

Browse files
committed
python: eliminate -Wundef warning about NPY_INTERNAL_BUILD
numpy 1.13.0+
1 parent 89172c0 commit ea6fe71

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

modules/python/common.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ if(MSVC AND NOT ENABLE_NOISY_WARNINGS)
118118
endif()
119119

120120
ocv_warnings_disable(CMAKE_CXX_FLAGS -Woverloaded-virtual -Wunused-private-field)
121+
ocv_warnings_disable(CMAKE_CXX_FLAGS -Wundef) # accurate guard via #pragma doesn't work (C++ preprocessor doesn't handle #pragma)
121122

122123
if(MSVC AND NOT BUILD_SHARED_LIBS)
123124
set_target_properties(${the_module} PROPERTIES LINK_FLAGS "/NODEFAULTLIB:atlthunk.lib /NODEFAULTLIB:atlsd.lib /DEBUG")

0 commit comments

Comments
 (0)