Commit 99b24f77 authored by Andrey Kamaev's avatar Andrey Kamaev

Fixed problem with backslashes in embedded build information.

parent dcadc4f8
......@@ -108,9 +108,8 @@ set(OPENCV_BUILD_INFO_FILE "${OpenCV_BINARY_DIR}/version_string.tmp")
file(REMOVE "${OPENCV_BUILD_INFO_FILE}")
function(ocv_output_status msg)
message(STATUS "${msg}")
if(msg MATCHES "\"")
string(REPLACE "\"" "\\\"" msg "${msg}")
endif()
string(REPLACE "\\" "\\\\" msg "${msg}")
string(REPLACE "\"" "\\\"" msg "${msg}")
file(APPEND "${OPENCV_BUILD_INFO_FILE}" "\"${msg}\\n\"\n")
endfunction()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment