From: Alexander Alekhin Date: Tue, 2 Jan 2018 19:16:51 +0000 (+0000) Subject: cmake: avoid unnecessary files creation in ocv_cmake_configure() X-Git-Tag: accepted/tizen/6.0/unified/20201030.111113~213^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=94b236872ccccf07ce9531a5928d84d79aa287d0;p=platform%2Fupstream%2Fopencv.git cmake: avoid unnecessary files creation in ocv_cmake_configure() --- diff --git a/cmake/OpenCVUtils.cmake b/cmake/OpenCVUtils.cmake index 8b836c1..47e37a3 100644 --- a/cmake/OpenCVUtils.cmake +++ b/cmake/OpenCVUtils.cmake @@ -32,8 +32,8 @@ function(ocv_cmake_eval var_name) endfunction() macro(ocv_cmake_configure file_name var_name) - configure_file(${file_name} "${CMAKE_BINARY_DIR}/CMakeConfig-${var_name}.cmake" ${ARGN}) - file(READ "${CMAKE_BINARY_DIR}/CMakeConfig-${var_name}.cmake" ${var_name}) + file(READ "${file_name}" __config) + string(CONFIGURE "${__config}" ${var_name} ${ARGN}) endmacro() macro(ocv_update VAR)