mirror of
https://github.com/opencv/opencv.git
synced 2025-06-11 11:45:30 +08:00
cmake: reset __content variable if file doesn't exist
Resolves CMake error after relaunch with updated source code: Cannot find source file: modules/dnn/layers/layers_common.avx512_skx.cpp
This commit is contained in:
parent
17233c687e
commit
14032c6653
@ -760,6 +760,8 @@ macro(ocv_add_dispatched_file filename)
|
|||||||
set(__file "${CMAKE_CURRENT_BINARY_DIR}/${filename}.${OPT_LOWER}.cpp")
|
set(__file "${CMAKE_CURRENT_BINARY_DIR}/${filename}.${OPT_LOWER}.cpp")
|
||||||
if(EXISTS "${__file}")
|
if(EXISTS "${__file}")
|
||||||
file(READ "${__file}" __content)
|
file(READ "${__file}" __content)
|
||||||
|
else()
|
||||||
|
set(__content "")
|
||||||
endif()
|
endif()
|
||||||
if(__content STREQUAL __codestr)
|
if(__content STREQUAL __codestr)
|
||||||
#message(STATUS "${__file} contains up-to-date content")
|
#message(STATUS "${__file} contains up-to-date content")
|
||||||
|
Loading…
Reference in New Issue
Block a user