Fixed Visual Studio precompiled headers

pull/2/head
Andrey Kamaev 13 years ago
parent f7c1d16b38
commit 0f01d8df1c
  1. 2
      cmake/OpenCVPCHSupport.cmake

@ -328,7 +328,7 @@ ENDMACRO(ADD_NATIVE_PRECOMPILED_HEADER)
macro(ocv_add_precompiled_header_to_target the_target pch_header)
if(PCHSupport_FOUND AND ENABLE_PRECOMPILED_HEADERS AND EXISTS "${pch_header}")
if(CMAKE_GENERATOR MATCHES Visual)
set(${the_target}_pch "${pch_header}")
string(REGEX REPLACE "hpp$" "cpp" ${the_target}_pch "${pch_header}")
add_native_precompiled_header(${the_target} ${pch_header})
unset(${the_target}_pch)
elseif(CMAKE_GENERATOR MATCHES Xcode)

Loading…
Cancel
Save