|
|
|
@ -110,14 +110,12 @@ if(POLICY CMP0056) |
|
|
|
|
cmake_policy(SET CMP0056 NEW) |
|
|
|
|
endif() |
|
|
|
|
|
|
|
|
|
include(cmake/OpenCVUtils.cmake) |
|
|
|
|
|
|
|
|
|
if(OPENCV_CXX11) |
|
|
|
|
#cmake_minimum_required(VERSION 3.1.0 FATAL_ERROR) |
|
|
|
|
set(CMAKE_CXX_STANDARD 11) |
|
|
|
|
set(CMAKE_CXX_STANDARD_REQUIRED TRUE) |
|
|
|
|
if(POLICY CMP0067) |
|
|
|
|
cmake_policy(SET CMP0067 NEW) |
|
|
|
|
endif() |
|
|
|
|
|
|
|
|
|
include(cmake/OpenCVUtils.cmake) |
|
|
|
|
|
|
|
|
|
# must go before the project command |
|
|
|
|
ocv_update(CMAKE_CONFIGURATION_TYPES "Debug;Release" CACHE STRING "Configs" FORCE) |
|
|
|
|
if(DEFINED CMAKE_BUILD_TYPE) |
|
|
|
@ -149,6 +147,7 @@ endif() |
|
|
|
|
# ---------------------------------------------------------------------------- |
|
|
|
|
# Detect compiler and target platform architecture |
|
|
|
|
# ---------------------------------------------------------------------------- |
|
|
|
|
OCV_OPTION(ENABLE_CXX11 "Enable C++11 compilation mode" "${OPENCV_CXX11}") |
|
|
|
|
include(cmake/OpenCVDetectCXXCompiler.cmake) |
|
|
|
|
|
|
|
|
|
# Add these standard paths to the search paths for FIND_LIBRARY |
|
|
|
@ -305,7 +304,6 @@ OCV_OPTION(INSTALL_TESTS "Install accuracy and performance test binar |
|
|
|
|
|
|
|
|
|
# OpenCV build options |
|
|
|
|
# =================================================== |
|
|
|
|
OCV_OPTION(OPENCV_CXX11 "Enable C++11 compilation mode" OFF ) |
|
|
|
|
OCV_OPTION(ENABLE_CCACHE "Use ccache" (UNIX AND NOT IOS AND (CMAKE_GENERATOR MATCHES "Makefile" OR CMAKE_GENERATOR MATCHES "Ninja")) ) |
|
|
|
|
OCV_OPTION(ENABLE_PRECOMPILED_HEADERS "Use precompiled headers" ON IF (NOT IOS AND NOT CMAKE_CROSSCOMPILING) ) |
|
|
|
|
OCV_OPTION(ENABLE_SOLUTION_FOLDERS "Solution folder in Visual Studio or in other IDEs" (MSVC_IDE OR CMAKE_GENERATOR MATCHES Xcode) ) |
|
|
|
@ -963,8 +961,8 @@ string(STRIP "${OPENCV_COMPILER_STR}" OPENCV_COMPILER_STR) |
|
|
|
|
status("") |
|
|
|
|
status(" C/C++:") |
|
|
|
|
status(" Built as dynamic libs?:" BUILD_SHARED_LIBS THEN YES ELSE NO) |
|
|
|
|
if(OPENCV_CXX11) |
|
|
|
|
status(" C++11:" "YES") |
|
|
|
|
if(ENABLE_CXX11 OR HAVE_CXX11) |
|
|
|
|
status(" C++11:" HAVE_CXX11 THEN YES ELSE NO) |
|
|
|
|
endif() |
|
|
|
|
status(" C++ Compiler:" ${OPENCV_COMPILER_STR}) |
|
|
|
|
status(" C++ flags (Release):" ${CMAKE_CXX_FLAGS} ${CMAKE_CXX_FLAGS_RELEASE}) |
|
|
|
|