简体   繁体   中英

Visual Studio 2013 not recreating pdb files

I have a weird problem with PDB files in a VS 2013 C# project. Basically what is happening is that the PDB files are not getting rebuilt when the project is getting rebuilt. This is causing the project to always think it needs to get rebuilt. I've tried cleaning the solution, but if anything changes in the project it gets put back into the same state again.

I created a simple class library project and the behavior was the same. As a sanity check, I created the same class library on another PC and it worked as I would have expected.

Does anybody have any ideas as to what might be causing this strange behavior?

Please check “Advanced Build Settings Dialog Box”

Is “Debug Info” set none?

see MSDN

I had this problem. I went into Build > Configuration Manager. Make sure that the active solution configuration is Debug. Next change the platform to be Any CPU. Somehow many projects were getting built on a mixed platform which was only allowing a couple project's pdb files to get built.

I have exactly the same problem. The only solution I've managed to come up with is to add a pre-build step to each project to delete the .pdb:

del "$(ProjectDir)obj\\$(Configuration)\\$(TargetName).pdb"

Which then seems to force it to create a new file when it's built.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM