在启用优化或没有调试信息的情况下构建

发布于 2024-08-15 18:54:21 字数 1133 浏览 6 评论 0原文

我目前正在尝试找出为什么我的 InjectableAttributes 永远不会到达过滤器部分
因此,我直接链接到源项目,这样我就可以轻松地放置断点等。
但是,当我构建时,我收到以下消息:

The following module was built either with optimizations enabled or without debug information: 
C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\root\[a bunch of randomly named directories]\assembly\[more random names]\MvcTurbine.Web.DLL]

To debug this module, change its project build configuration to Debug mode. To suppress this message, disable the 'Warn if no user code on launch' debugger option.

我检查了项目的属性。它的配置设置为“活动(调试)”并且“优化代码”复选框未选中。

更新
我再次检查了我是否无意中包含了该文件而不是项目,但引用似乎是正确的。
为了确保我还删除了所有现有的垃圾箱,以便所有库都肯定会在某个地方重建,但无济于事。

更新
在高级“构建”窗口中,“调试”输出设置为“完整”,并且所有选项与正在构建调试信息的项目相同。
配置管理器显示该项目正在构建,并且具有与所有其他选项完全相同的设置。

更新
在“调试”->“Windows-模块”窗口中,涡轮机库的符号状态为 PDB 文件与图像不匹配 我删除了整个系统上所有相应的 pdb 文件,以确保它重新生成,但无济于事。
为了确保我还在整个系统上搜索了该 dll 并将其删除。没有什么。

什么会阻止 VS 创建调试信息?

I'm currently trying to find out why my InjectableAttributes never get to the filter part.
Therefor I linked in the source project directly so I could easily put breakpoints etc.
When I build however I get the following message:

The following module was built either with optimizations enabled or without debug information: 
C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\root\[a bunch of randomly named directories]\assembly\[more random names]\MvcTurbine.Web.DLL]

To debug this module, change its project build configuration to Debug mode. To suppress this message, disable the 'Warn if no user code on launch' debugger option.

I checked the project's properties. It's configuration is set to "Active(Debug)" and the "Optimize code" check box is unchecked.

UPDATE
I checked again if I didn't by accident include the file rather then the project, but the references seem correct.
Just to be sure I also removed all existing bins so that all libraries are definitely rebuild somewhere, but to no avail.

UPDATE
In the advanced Build window the Debug output is set to Full and all options are identical to projects that are building debug info.
The config manager shows that the project is being built and has the exact same settings as all the other options.

UPDATE
In the Debug->Windows-Modules window the symbol status for the turbine library is PDB file does not match image I removed all corresponding pdb files on my entire system to make sure it gets re-generated, but to no avail.
To make sure I also searched for the dll on my entire system and removed them. Nothing.

What can be preventing VS from creating debug information?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

沫离伤花 2024-08-22 18:54:21

我今天早上刚刚使用VS2010遇到了同样的问题。我通过删除所有构建工件(例如可执行文件、库、PDB 等)解决了这个问题。这位于 \bin\Debug、\bin\Release、\obj\Debug 和 \obj\Release (包括子文件夹)中。然后我重新编译了调试配置,并重新开始工作。

I've just experienced the same problem this morning, using VS2010. I solved it by deleting all the build artefacts, e.g. executables, libraries, PDBs, etc. This was in \bin\Debug, \bin\Release, \obj\Debug, and \obj\Release (including sub-folders). Then I recompiled the debug configuration, and was back in business.

花伊自在美 2024-08-22 18:54:21

检查是否正在为项目生成调试信息。您可以通过打开“项目属性”页面上的“构建”选项卡并单击“高级...”按钮来执行此操作。检查“调试信息”设置。请参阅这篇 MSDN 文章,了解每个选项含义的说明。

如果这不能解决问题,请检查 MvcTurbine 项目是否确实正在构建(Build -> Configuration Manager)。

Check that debug info is being generated for the project. You can do this by opening the Build tab on the Project Properties page and clicking the "Advanced..." button. Check the "Debug Info" setting. See this MSDN article for an explanation of what each option means.

If that doesn't solve it, check that the MvcTurbine project is actually being built (Build -> Configuration Manager).

初熏 2024-08-22 18:54:21

听起来您好像引用了 MvcTurbine.Web.DLL 文件,而不是 MvcTurbine 项目。尝试删除引用并将其重新添加为项目引用。

更新 您确定 DLL 不是来自 GAC 吗?当应用程序运行时执行“调试”->“Windows”->“模块”并检查“路径”列。

It sounds like you've referenced the MvcTurbine.Web.DLL file rather than the MvcTurbine project. Try removing the reference and re-adding it as a project reference.

Update Are you sure the DLL isn't coming from the GAC? Do Debug->Windows->Modules when the app is running and check the Path column.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文