VS2005,工程无法debug调试的问题
是这样的,我的工程以前是可以调试的,只要调在debug模式下就可以了,也可以添加断点。但最近拿出来用的时候,发现无法调试了,即使设置在debug模式下面,也依旧不能添加断点,编译运行的时候会弹出对话框“debugging information for "MyProject" cannot be found or does not match. No symbols loaded”
我找了很久,如下的方法我都尝试过了:
To enable debugging:
1) Goto Project->HelloWorld Properties
2) On the left expand "Configuration Properties"
3) Expand "C/C++"
4) On the left, Select "General"
5) On the right, change "Debug Information Format" to "Program Database For Edit And Continue (/ZI)"
5) On the left, Select "Optimization"
6) On the right, change "Optimization" to "Disabled (/Od)"
7) On the left, expand "Linker"
8) On the left, select "Debugging"
9) On the right, change "Generate Debug Info" to "Yes"
10) Click ok
11) Set your breakpoints
12) Rebuild your application
Here are the steps I took:
1) Open your Project Properties..
2) On the left, expand Configuration Properties.
3) Just beneath that, select "General" under Configuration Properties.
4) On the right, change "Debuggable Assembly" to "Runtime tracking and disable optimizations (/ASSEMBLYDEBUG)"
5) Click OK to save changes.
结果还是一样,完全无法调试。此外这个工程在debug下面编译也有问题,每次无论做没做改动,只要点了start,就一定会重头开始编译一遍。尝试修改了precompiled header 但还是有问题。
请问遇到这种情况应该怎么办?
刚才又看了一下,debug输出这样:
'ShaderTest2': Loaded 'E:\Documents and Settings\Administrator\My Documents\Visual Studio Projects\ShaderTest2\Debug\ShaderTest2', No symbols loaded.
'ShaderTest2': Loaded 'E:\WINDOWS\system32\ntdll.dll', No symbols loaded.
'ShaderTest2': Loaded 'E:\WINDOWS\system32\kernel32.dll', No symbols loaded.
'ShaderTest2': Loaded 'E:\WINDOWS\system32\gdi32.dll', No symbols loaded.
觉得很奇怪,下面的dll没有symbols就算了,为什么我编译出来的exe也没有呢?
ShaderTest2.pdb明明就在那里。。