When i run my program in opencv c++ visual studio 2010 the program run but i show the following error's , What this error want to install further more ?
'WK01.exe': Loaded 'C:\Users\Sheikh\Documents\Visual Studio 2010\Projects\WK01\Debug\WK01.exe', Symbols loaded.
'WK01.exe': Loaded 'C:\Windows\System32\ntdll.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Program Files\Alwil Software\Avast5\snxhk.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\kernel32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\KernelBase.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\opencv_core244d.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\msvcp100d.dll', Symbols loaded.
'WK01.exe': Loaded 'C:\Windows\System32\msvcr100d.dll', Symbols loaded.
'WK01.exe': Loaded 'C:\Windows\System32\opencv_highgui244d.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\user32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\gdi32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\lpk.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\usp10.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\msvcrt.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\ole32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\rpcrt4.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\oleaut32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\advapi32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\sechost.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.windows.common-controls_6595b64144ccf1df_5.82.7601.17514_none_ec83dffa859149af\comctl32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\avifil32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\winmm.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\msacm32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\msvfw32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\shell32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\shlwapi.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\avicap32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\version.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\imm32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\msctf.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\opencv_ffmpeg244.dll', Binary was not built with debug information.
'WK01.exe': Loaded 'C:\Windows\System32\wsock32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\ws2_32.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\nsi.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\cryptbase.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\uxtheme.dll', Cannot find or open the PDB file
'WK01.exe': Loaded 'C:\Windows\System32\dwmapi.dll', Cannot find or open the PDB file
The program '[4156] WK01.exe: Native' has exited with code 0 (0x0).
These are not errors, they are just informational messages from the debugger.
When a program is compiled in Debug mode (and optionally in Release mode), a .pdb file is also produced, that associates function names and variable names in the source code with the corresponding locations in the compiled code. It's this information that Visual Studio uses to show you source code and variable values as you step through the program.
All that's happening here is that your program is running in the debugger and is loading system DLLs and other modules that don't have a .pdb file, so it's telling you that it won't be able to show equivalent source code for these modules.
Summary. It's normal, not an error.
Related
I've got a third party executable with related .pdb and .idb files. I load Visual Studio Community and open this executable as solution.
After trying to debug I see no info, in the modules window the following message appears for the exe: Binary was not built with debug information
Both the pdb and idb files are in the same folder as the executable, in the same folder, and I've added that folder to the proper section in tools > options > debugging > symbols.
Still the same message.
I am working on a speech recognition children's game using an external API that I want to use on my project. Said API has lib files, dll files, header files and cpp files. As of right now I have successfully added the library files (at least I think I have) to my project directory, added all the necessary header files to external dependencies and I am left to add two .dll files to my project. First, I add my Audio.dll file and it gets added perfectly with no issues. Second, I add my Speech.dll and here is where my problem arises. I don't receieve any errors in my debug error list, however, the output of my project looks like this:
'Project.exe' (Win32): Loaded 'C:\Path\Project.exe'. Symbols loaded.
'Project.exe' (Win32): Loaded 'C:\Windows\System32\ntdll.dll'. Cannot find or open the PDB file.
'Project.exe' (Win32): Loaded 'C:\Windows\System32\mscoree.dll'. Cannot find or open the PDB file.
'Project.exe' (Win32): Loaded 'C:\Windows\System32\kernel32.dll'. Cannot find or open the PDB file.
'Project.exe' (Win32): Loaded 'C:\Windows\System32\KernelBase.dll'. Cannot find or open the PDB file.
'Project.exe' (Win32): Loaded 'C:\Windows\System32\ucrtbased.dll'. Cannot find or open the PDB file.
'Project.exe' (Win32): Loaded 'C:\Windows\System32\vcruntime140d.dll'. Cannot find or open the PDB file.
The thread 0x3274 has exited with code -1073741515 (0xc0000135).
The thread 0x198c has exited with code -1073741515 (0xc0000135).
The program '[17020] Project.exe' has exited with code -1073741515 (0xc0000135) 'A dependent dll was not found'.
After this I get a popup System Error: The code execution cannot proceed because Speech.dll was not found. Reinstalling the program may fix this problem.
No mention of Audio.dll, however, Speech.dll which is in the same folder as Audio.dll isn't being found. I tried reinstalling the .dll, I tried reinstalling Visual Studio 2017, I tried Add->Existing Item->.dll, I tried adding the dll to the project path where the .exe is and I've tried adding it to every folder/subfolder all receiving the same sequence as my output.
My question is, how do I get my visual studio 2017 project to recognize my Speech.dll file?
Please ensure that the speech.dll is present in the same folder that your project.exe is located.
Windows searches for the dlls in the following order:
Your application's folder
\windows\system32
etc, according to the Windows defined path
Please ensure that the dll is present in any of these folders, otherwise you will get an error that the dll missing.
Note: If you are debugging then ensure that you have set the Working Directory for debugging correctly to point to the folder containing your project.exe and the dll.
In Visual Studio 2019 (I'm not aware if this would work on earlier versions),you can copy the DLL as part of the of the build process. Basically you would need to add a post-build event to your project. The post-build event would copy the DLL to your build output directory.
For specifying build events see:
https://learn.microsoft.com/en-us/cpp/build/specifying-build-events?view=msvc-160
The command you would use for the post-build event would be:
xcopy /y /d "<relative path or absolute path to dll location>/youlib.dll" "$(outdir)"
I'm using a symbol/source server to store private nuget packages. The packages are built using the "nuget pack" command using the -symbols flag and then pushed to the server.
Visual Studio (2015) correctly loads the symbols/source from the server the first time that particular package is being debugged. The problem occurs when I try to debug a different version of that package. Whenever there is any version of a source file available in the SymbolCache directory, Visual Studio will use that one to debug.
When I clear the SymbolCache directory, it does load the correct file version again from the symbol/source server and puts it in the SymbolCache.
example:
I have a package "testpackage" with version 1.0.1 being used by Application-A and Application-B uses testpackage version 1.0.2
I debug into code from testpackage through Application-B
The source files for testpackage 1.0.2 are copied to the SymbolCache directory and used correctly while debugging
I debug into code from testpackage through Application-A
The source files from version 1.0.2 are used instead of 1.0.1
In step 6 I would expect version 1.0.1 to be copied to the SymbolCache directory and used in debugging
I checked the Modules window during debug, and it shows that the correct pdb is loaded from cache, or if not present the pdb is loaded from the symbol server. There is a directory with symbol files for each package version.
Even though the correct symbol file is used, it still loads the wrong source file until I clear the SymbolCache.
Visual Studio loads the incorrect file version from SymbolCache for debugging
This issue may caused by mismatch of the pdb file. You can select Debug -> Windows -> Modules, on the Modules window, right click the symbol item, select Symbol Load Information, from the pop up window, you can see whether the pdb file is loaded and where the pdb file is loaded from.
If the pdb file is loaded from incorrect path, you may specify a correct symbol location by clicking the Symbol Settingsā¦ button (on theĀ Symbol Load Information dialog).
If the pdb file is loaded from correct place, your issue may caused by mismatch of the pdb file, clear the SymbolCache directory and reload it from the symbol/source server may help.
AFAIK, If your SymbolCache folder had the old version symbols file which was downloaded from the Symbol Server before, it would not download it again during you debug your app. One possible reason is that since your symbol file has the same name but in different versions, the VS debugging would search and load the symbol file from your SymbolCache folder firstly, and then download it from the symbol server or others if your SymbolCache folder has no them. That's the reason why you got this issue.
A workarounds I could suggest: Using different names would be better.
Hope this can help you understand this question.
I have an executable, its pdb file, and the corresponding source in VS2010/2012. How can I debug the exe which gives the same effect as debugging in conventional ways.
It would be great if you can mention steps. Thanks :)
You can open a .exe as a project (without creating any additional project files and such):
Put the .pdb file next to the .exe
Start Visual Studio
File -> Open -> Project/Solution
Find your .exe and click Open
Start debugging
I am debugging a VS 2008 C++ project. The project links to a static lib whose PDB file is present in same folder as the .lib file. It used to be all OK. PDB of lib file is loaded and source file is accessible during debugging. But now it suddenly fail to load with no change at all.
So how do I diagnose in VC++ to make sure the pdb is found and loaded by IDE?
UPDATE:
I changed EXE project setting to be "YES" for "Use library dependency inputs", and now I can access source code of the lib now, though it doesn't answer my initial question of why pdb of lib suddenly fails to load.
Further Question
My understanding is: EXE file statically links to LIB file, so all referenced binary code in LIB are already included in EXE binary. So do I actually need LIB file present? And, do I need LIB pdb file present or are the debugging info integrated into EXE's pdb file as well?