mirror of
https://github.com/opencv/opencv.git
synced 2025-01-18 22:44:02 +08:00
Merge pull request #22527 from paroj:misc
This commit is contained in:
commit
584ea43b2f
@ -331,7 +331,8 @@ ENDMACRO(ADD_PRECOMPILED_HEADER)
|
||||
MACRO(GET_NATIVE_PRECOMPILED_HEADER _targetName _input)
|
||||
|
||||
if(ENABLE_PRECOMPILED_HEADERS)
|
||||
if(CMAKE_GENERATOR MATCHES "^Visual.*$")
|
||||
if(CMAKE_GENERATOR MATCHES "^Visual.*$"
|
||||
AND (CMAKE_VERSION VERSION_LESS "3.16" OR OPENCV_SKIP_CMAKE_BUILTIN_PCH)) # with 3.16+ we use target_precompile_headers
|
||||
set(${_targetName}_pch ${CMAKE_CURRENT_BINARY_DIR}/${_targetName}_pch.cpp)
|
||||
endif()
|
||||
endif()
|
||||
@ -406,7 +407,9 @@ 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" OR CMAKE_GENERATOR MATCHES Xcode)
|
||||
if(NOT CMAKE_VERSION VERSION_LESS "3.16" AND NOT OPENCV_SKIP_CMAKE_BUILTIN_PCH)
|
||||
target_precompile_headers(${the_target} PRIVATE ${pch_header})
|
||||
elseif(CMAKE_GENERATOR MATCHES "^Visual" OR CMAKE_GENERATOR MATCHES Xcode)
|
||||
add_native_precompiled_header(${the_target} ${pch_header})
|
||||
elseif(CV_GCC AND CMAKE_GENERATOR MATCHES "Makefiles|Ninja")
|
||||
add_precompiled_header(${the_target} ${pch_header})
|
||||
|
@ -160,7 +160,7 @@ public:
|
||||
double wr[27], wi[27] = {0}; // 27 = mat_order
|
||||
std::vector<double> work(lwork), eig_vecs(729);
|
||||
char jobvl = 'N', jobvr = 'V'; // only left eigen vectors are computed
|
||||
dgeev_(&jobvl, &jobvr, &mat_order, (double*)solution_polynomial.data, &lda, wr, wi, nullptr, &ldvl,
|
||||
OCV_LAPACK_FUNC(dgeev)(&jobvl, &jobvr, &mat_order, (double*)solution_polynomial.data, &lda, wr, wi, nullptr, &ldvl,
|
||||
&eig_vecs[0], &ldvr, &work[0], &lwork, &info);
|
||||
if (info != 0) return 0;
|
||||
#endif
|
||||
|
@ -161,7 +161,7 @@ public:
|
||||
int mat_order = 10, info, lda = 10, ldvl = 10, ldvr = 1, lwork = 100;
|
||||
double wr[10], wi[10] = {0}, eig_vecs[100], work[100]; // 10 = mat_order, 100 = lwork
|
||||
char jobvl = 'V', jobvr = 'N'; // only left eigen vectors are computed
|
||||
dgeev_(&jobvl, &jobvr, &mat_order, action_mat_data, &lda, wr, wi, eig_vecs, &ldvl,
|
||||
OCV_LAPACK_FUNC(dgeev)(&jobvl, &jobvr, &mat_order, action_mat_data, &lda, wr, wi, eig_vecs, &ldvl,
|
||||
nullptr, &ldvr, work, &lwork, &info);
|
||||
if (info != 0) return 0;
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user