opencv cannot find feature2d/test/test_detectors_regression.impl.hpp file
When compiling opencv 's cmake, I encountered a problem that the feature2d/test/test_detectors_regression.impl.hpp file could not be found.
Where to find this file first:
find -name test_detectors_regression.impl.hpp
Found that this path is in the modules directory under opencv:
Why can't I find it, I look at the run command of make:
It is found that the sequence of the -I parameter in the gcc execution command that reports the error does not contain the modules path.
Knowing the problem is simple, the solution is to add this parameter.
I did it by modifying the CMakeLists.txt of the project, the simple and violent kind:
Add on line 567:
That's it! !