Skip to content

Commit

Permalink
Merge pull request opencv#14339 from alalek:cmake_fix_std_cxx11
Browse files Browse the repository at this point in the history
  • Loading branch information
alalek committed Apr 16, 2019
2 parents 4635356 + a56c122 commit 7ad5d21
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
2 changes: 1 addition & 1 deletion cmake/OpenCVDetectCXXCompiler.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ if(CMAKE_CXX11_COMPILE_FEATURES)
endif()
if(NOT HAVE_CXX11)
ocv_check_compiler_flag(CXX "" HAVE_CXX11 "${OpenCV_SOURCE_DIR}/cmake/checks/cxx11.cpp")
if(NOT HAVE_CXX11 AND ENABLE_CXX11)
if(NOT HAVE_CXX11)
ocv_check_compiler_flag(CXX "-std=c++11" HAVE_STD_CXX11 "${OpenCV_SOURCE_DIR}/cmake/checks/cxx11.cpp")
if(HAVE_STD_CXX11)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
Expand Down
7 changes: 0 additions & 7 deletions cmake/OpenCVDetectInferenceEngine.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,6 @@
# INF_ENGINE_TARGET - set to name of imported library target representing InferenceEngine
#

if(NOT HAVE_CXX11)
message(WARNING "DL Inference engine requires C++11. You can turn it on via ENABLE_CXX11=ON CMake flag.")
return()
endif()

# =======================

function(add_custom_ie_build _inc _lib _lib_rel _lib_dbg _msg)
if(NOT _inc OR NOT (_lib OR _lib_rel OR _lib_dbg))
return()
Expand Down

0 comments on commit 7ad5d21

Please sign in to comment.