找不到程序.dll文件

时间:2019-03-31 01:33:44

标签: c++ opencv

我尝试遵循https://docs.opencv.org/3.1.0/d4/d18/tutorial_sfm_scene_reconstruction.html此代码,但无法构建。我使用opencv和额外贡献版本3.4.5

我试图将.dll添加到项目中,但是它不起作用。

'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ntdll.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\kernel32.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\KernelBase.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'E:\opencv\laster\install\x86\vc15\bin\opencv_core345d.dll'. Symbols loaded.
'scenceRecon.exe' (Win32): Loaded 'E:\opencv\laster\install\x86\vc15\bin\opencv_sfm345d.dll'. Symbols loaded.
'scenceRecon.exe' (Win32): Loaded 'E:\opencv\laster\install\x86\vc15\bin\opencv_viz345d.dll'. Symbols loaded.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msvcp140d.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\vcruntime140d.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ucrtbased.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\concrt140d.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'E:\opencv\laster\install\x86\vc15\bin\opencv_xfeatures2d345d.dll'. Symbols loaded.
'scenceRecon.exe' (Win32): Loaded 'E:\opencv\laster\install\x86\vc15\bin\opencv_features2d345d.dll'. Symbols loaded.
'scenceRecon.exe' (Win32): Loaded 'E:\opencv\laster\install\x86\vc15\bin\opencv_flann345d.dll'. Symbols loaded.
'scenceRecon.exe' (Win32): Loaded 'E:\opencv\laster\install\x86\vc15\bin\opencv_imgcodecs345d.dll'. Symbols loaded.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\user32.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\win32u.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\gdi32.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\gdi32full.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msvcp_win.dll'. Cannot find or open the PDB file.
'scenceRecon.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ucrtbase.dll'. Cannot find or open the PDB file.
The thread 0x27dc has exited with code -1073741515 (0xc0000135).
The thread 0x1f78 has exited with code -1073741515 (0xc0000135).
The program '[6608] scenceRecon.exe' has exited with code -1073741515 (0xc0000135) 'A dependent dll was not found'.```

和此.exe错误

1 个答案:

答案 0 :(得分:1)

这是Windows API框架的常见模式。您安装/构建一些框架,该框架附带了一组INCLUDE,LIB和DLL文件。您的代码包括标头和DLL的存根lib文件的链接,以便进行编译。但是在运行时,找不到依赖的DLL,因为它们不在您的PATH中(或与EXE相同的文件夹中)。

对话框从字面上告诉您错误。将ceres-debug.dll复制到与EXE相同的文件夹中。或者最好如上所述,只要确保PATH环境变量中包含ceres-debug.dll的任何文件夹即可。通过更新PATH,您可能会解决程序或ceres-debug.dll所依赖的其他DLL的许多后续错误。

有道理吗?

此外,针对“ DLL搜索顺序”的快速Google文章中有几篇很好的文章对此主题进行了解释:https://docs.microsoft.com/en-us/windows/desktop/Dlls/dynamic-link-library-search-order