From de8b3ee231f8e730c01acb5d2c57a8b4b554ddcb Mon Sep 17 00:00:00 2001 From: Alexander Alekhin Date: Tue, 9 Feb 2016 14:24:56 +0300 Subject: [PATCH 1/3] cmake: add timestamp into build info log (6089) --- CMakeLists.txt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7be7259dd..6ec4f518f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -759,6 +759,12 @@ endif() # ========================== build platform ========================== status("") status(" Platform:") +if(NOT CMAKE_VERSION VERSION_LESS 2.8.11 AND NOT BUILD_INFO_SKIP_TIMESTAMP) + string(TIMESTAMP TIMESTAMP "" UTC) + if(TIMESTAMP) + status(" Timestamp:" ${TIMESTAMP}) + endif() +endif() status(" Host:" ${CMAKE_HOST_SYSTEM_NAME} ${CMAKE_HOST_SYSTEM_VERSION} ${CMAKE_HOST_SYSTEM_PROCESSOR}) if(CMAKE_CROSSCOMPILING) status(" Target:" ${CMAKE_SYSTEM_NAME} ${CMAKE_SYSTEM_VERSION} ${CMAKE_SYSTEM_PROCESSOR}) From 1dac67f0137ec387022d285b1ba95e5d8f03a69e Mon Sep 17 00:00:00 2001 From: Alexander Alekhin Date: Tue, 9 Feb 2016 14:36:42 +0300 Subject: [PATCH 2/3] cmake: add version control revision info for extra modules --- CMakeLists.txt | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6ec4f518f..89756b14d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -755,6 +755,36 @@ status("General configuration for OpenCV ${OPENCV_VERSION} ===================== if(OPENCV_VCSVERSION) status(" Version control:" ${OPENCV_VCSVERSION}) endif() +if(OPENCV_EXTRA_MODULES_PATH AND NOT BUILD_INFO_SKIP_EXTRA_MODULES) + set(__dump_extra_header OFF) + foreach(p ${OPENCV_EXTRA_MODULES_PATH}) + if(EXISTS ${p}) + if(NOT __dump_extra_header) + set(__dump_extra_header ON) + status("") + status(" Extra modules:") + else() + status("") + endif() + set(EXTRA_MODULES_VCSVERSION "unknown") + if(GIT_FOUND) + execute_process(COMMAND "${GIT_EXECUTABLE}" describe --tags --always --dirty --match "[0-9].[0-9].[0-9]*" + WORKING_DIRECTORY "${p}" + OUTPUT_VARIABLE EXTRA_MODULES_VCSVERSION + RESULT_VARIABLE GIT_RESULT + ERROR_QUIET + OUTPUT_STRIP_TRAILING_WHITESPACE + ) + if(NOT GIT_RESULT EQUAL 0) + set(EXTRA_MODULES_VCSVERSION "unknown") + endif() + endif() + status(" Location (extra):" ${p}) + status(" Version control (extra):" ${EXTRA_MODULES_VCSVERSION}) + endif() + endforeach() + unset(__dump_extra_header) +endif() # ========================== build platform ========================== status("") From 9ac35173e32471a8485e303c0e14be99060bb074 Mon Sep 17 00:00:00 2001 From: Alexander Alekhin Date: Tue, 9 Feb 2016 14:44:05 +0300 Subject: [PATCH 3/3] cmake: remove non-ascii symbols --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 89756b14d..0065507b3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -693,7 +693,7 @@ include(cmake/OpenCVGenPkgconfig.cmake) # Generate OpenCV.mk for ndk-build (Android build tool) include(cmake/OpenCVGenAndroidMK.cmake) -# Generate OpenCVŠ”onfig.cmake and OpenCVConfig-version.cmake for cmake projects +# Generate OpenCVConfig.cmake and OpenCVConfig-version.cmake for cmake projects include(cmake/OpenCVGenConfig.cmake) # Generate Info.plist for the IOS framework