如何调试静态依赖加载问题? [英] How to debug static dependency loading problems?

查看:39
本文介绍了如何调试静态依赖加载问题?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何调试 Visual C++ 2010 SP1 应用程序无法完全加载其依赖项并过早退出而不显示其 UI 的场景?

How can I debug a scenario where a Visual C++ 2010 SP1 application is unable to completely load its dependencies, and quits prematurely, without showing its UI?

我对 Fusion Logs、dependency walker 和远程调试器的良好指南感兴趣,如果您认为它们相关的话.是否可以使用 WinDbg 轻松验证?Process Explorer 怎么样?

I am interested in a good guides to Fusion Logs, dependency walker, and remote debugger, if you think they are relevant. Is it something that can be easily verified with WinDbg? What about Process Explorer?

是否可以在附加了远程调试器的远程机器上启动进程?

Is it possible to launch a process on a remote machine with remote debugger attached?

是否可以验证是否安装了正确的 Visual C++ 2010 SP1 运行时?

Would it be possible to verify if a proper Visual C++ 2010 SP1 run-time is installed?

一个限制:应用程序在安装了 Visual Studio 的开发人员的盒子上运行良好.问题只能在干净的目标机器上观察到.这意味着安装工具链后问题可能会消失.

One limitation: the application runs fine on the developer's box with Visual Studio installed. Problem can only be observed on a clean target machine. This means that problem might disappear when a tool chain is installed.

推荐答案

是否可以在附加了远程调试器的远程计算机上启动进程?

Is it possible to launch a process on a remote machine with remote debugger attached?

当然可以.例如在 Visual Studio 2008 中,右键单击您的项目 -> 属性 -> 配置属性 -> 调试,在要启动的调试器"下拉列表中选择远程 Windows 调试器".然后在远程机器上输入 EXE 的完整路径,并根据参数(如果有).

Sure you can. For example in Visual Studio 2008, right-click your project -> Properties -> Configuration Properties -> Debugging, select "Remote Windows Debugger" in the "Debugger to launch" dropdown list. Then type the full path of your EXE on your remote machine and according arguments if any.

在此之前,您需要先在远程机器上运行远程调试监视器.将 \Program Files\Microsoft Visual Studio 9.0\Common7\IDE\Remote Debugger\x86(或其他平台)复制到您的远程机器上,然后运行 ​​msvsmon.exe.

Before doing so, you need first run remote debugging monitor on your remote machine. Copy \Program Files\Microsoft Visual Studio 9.0\Common7\IDE\Remote Debugger\x86(or other platform) to your remote machine, and run msvsmon.exe.

一般来说,如果你的应用因为缺少一些静态依赖而退出,你可以使用dependency walker来检查缺少哪一个.

Generally, if your application quits due to the missing of some static dependency, you can use dependency walker to check which one is missing.

这篇关于如何调试静态依赖加载问题?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆