I have successfully downloaded OpenCV source, configured CMake, and generated build files for Visual Studio 2019/Windows 10. I load the solution without any issue and the build proceeds without any issue. However, when the build finishes I find one error saying that the debug version of python39_d.lib was not found.
I don’t need python for what I am doing. CMake detected it and added it to the configuration. I see in the OpenCV source code at pyconfig.h the following code:
/* For an MSVC DLL, we can nominate the .lib files used by extensions */
/* not building the core - must be an ext */
/* So MSVC users need not specify the .lib file in their Makefile (other compilers are generally taken care of by distutils.) */
#endif /* MS_COREDLL */
It appears that this is the only place that python39_d.lib is referenced.
Can I safely ignore this error? Is there a preferred approach to linking with the non-debug version of the library? As I say, I don’t need python for what I am doing because I am working in C++.
Thank you for any insights.