cmake(opt): force separate targets for dispatched code
- PCH may not pass compilation flags properly
This commit is contained in:
parent
4a4b2a0ce6
commit
d480e2e51b
@ -680,7 +680,7 @@ macro(ocv_compiler_optimization_process_sources SOURCES_VAR_NAME LIBS_VAR_NAME T
|
|||||||
if(fname_LOWER MATCHES "\\.${OPT_LOWER}\\.cpp$")
|
if(fname_LOWER MATCHES "\\.${OPT_LOWER}\\.cpp$")
|
||||||
#message("${fname} BASELINE-${OPT}")
|
#message("${fname} BASELINE-${OPT}")
|
||||||
set(__opt_found 1)
|
set(__opt_found 1)
|
||||||
list(APPEND __result "${fname}")
|
list(APPEND __result_${OPT} "${fname}")
|
||||||
break()
|
break()
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
@ -714,7 +714,7 @@ macro(ocv_compiler_optimization_process_sources SOURCES_VAR_NAME LIBS_VAR_NAME T
|
|||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
foreach(OPT ${CPU_DISPATCH_FINAL})
|
foreach(OPT ${CPU_BASELINE_FINAL} ${CPU_DISPATCH_FINAL})
|
||||||
if(__result_${OPT})
|
if(__result_${OPT})
|
||||||
#message("${OPT}: ${__result_${OPT}}")
|
#message("${OPT}: ${__result_${OPT}}")
|
||||||
if(CMAKE_GENERATOR MATCHES "^Visual"
|
if(CMAKE_GENERATOR MATCHES "^Visual"
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user