error: ‘std::_hypot‘ has not been declared using std::hypot;

When Cmake uses the qt compiler to compile opencv, an error occurred when executing mingw32-make

The essential reason is that _hypot is not declared. So find the corresponding file and declare it.

E:\*****\Qt5.14.1\Tools\mingw730_64\lib\gcc\x86_64-w64-mingw32\7.3.0\include\c++ The math.h file below.
You can see that this file has a header file cmath.h, in the same folder, open this file, and add macro definitions to the file.

#define _hypot hypot
 

cmath.h and math.h are in the same folder 

Guess you like

Origin blog.csdn.net/Vertira/article/details/132633070