DEBUGFASTLINK需要目标文件 [英] DEBUGFASTLINK requires object files

查看:182
本文介绍了DEBUGFASTLINK需要目标文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经安装了SFML库,现在当我编译我的项目时弹出如下错误:


"source.obj的路径"...是用/构建的DEBUGFASTLINK需要oject文件进行调试。


后续失败将记录到Output窗口的Debug窗格中。


在输出中:


'Game_1.exe'(Win32):加载'B:\VISUALSTUDIOPROJECTS\Game_1 \Debug\Game_1.exe'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ antdll.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ kernel32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \KernelBase.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'B:\VISUALSTUDIOPROJECTS \Game_1 \Debug \sfml-graphics-d-2.dll'。无法找到或打开PDB文件。

'Game_1.exe'(Win32):已加载'B:\VISUALSTUDIOPROJECTS \Game_1 \Debug \sfml-window-d-2.dll' 。无法找到或打开PDB文件。

'Game_1.exe'(Win32):已加载'B:\VISUALSTUDIOPROJECTS \Game_1 \Debug\sfml-system-d-2.dll' 。无法找到或打开PDB文件。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ winmm.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ msvcrt.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ user32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ gdi32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ lpk.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ uspp.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ advapi32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \sechost.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \rpcrt4.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \sspicli.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \cryptbase.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \msvcp140d.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \vcruntime140d.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ucrtbased.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ api-ms-win-core-localization-l1-2-0.dll' 。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ api-ms-win-core-processthreads-l1-1-1.dll' 。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ api-ms-win-core-file-l1-2-0.dll' 。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ api-ms-win-core-timezone-l1-1-0.dll' 。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ api-ms-win-core-file-l2-1-0.dll' 。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ api-ms-win-core-synch-l1-2-0.dll' 。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \opengl32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ glulu.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ ddraw.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ dciman32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \setupapi.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \cfgmgr32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ odaut32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \\'ole32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ devobj.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \dwmapi.dll'。已加载符号。

错误:找不到'B:\VISUALSTUDIOPROJECTS \Game_1 \ Game_1 \Debug \ Source.obj'。 Game_1.exe是使用/ DEBUG:FASTLINK构建的,需要使用目标文件进行调试。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \imm32.dll' 。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ msctf.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ uxtheme.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ nvoglv32.dll'。无法找到或打开PDB文件。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ Shell32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \shlwapi.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \wtsapi32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ version.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ advapi32.dll'。已加载符号。

'Game_1.exe'(Win32):已卸载'C:\ Windows \SysWOW64 \advapi32.dll'
$
'Game_1.exe'( Win32):加载'C:\ Windows \SysWOW64 \ gdi32.dll'。已加载符号。

'Game_1.exe'(Win32):已卸载'C:\ Windows \SysWOW64 \ gdi32.dll'
$
'Game_1.exe'( Win32):加载'C:\ Windows \SysWOW64 \ wintrust.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \crypt32.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ msasn1.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ antmarta.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ Wldap32.dll'。加载符号。

线程0x2770已退出,代码为0(0x0)。

线程0x2774已退出,代码为0(0x0)。

线程0x277c已退出,代码为0(0x0)。

线程0x2778已退出,代码为0(0x0)。

'Game_1.exe'(Win32):加载'C:\ Windows \SysWOW64 \ Shell32.dll'。已加载符号。

'Game_1.exe'(Win32):已卸载'C:\ Windows \SysWOW64 \ shell32.dll'
$
'Game_1.exe'( Win32):加载'C:\ Windows \SysWOW64 \ nvspcap.dll'。无法找到或打开PDB文件。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \powrprof.dll'。已加载符号。

'Game_1.exe'(Win32):已卸载'C:\ Windows \SysWOW64 \powrprof.dll'
$
'Game_1.exe'( Win32):加载'C:\ Windows \SysWOW64 \ winsta.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \ dinput.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \hid.dll'。已加载符号。

'Game_1.exe'(Win32):已加载'C:\ Windows \SysWOW64 \\'ole32.dll'。已加载符号。

'Game_1.exe'(Win32):已卸载'C:\ Windows \SysWOW64 \ole32.dll'

线程0x2794已退出代码0(0x0)。

线程0x2780已退出,代码为0(0x0)。

线程0x278c已退出,代码为0(0x0)。

线程0x2788已退出,代码为0(0x0)。

线程0x2798已退出,代码为0(0x0)。

线程0x279c已退出代码0(0x0)。

程序'[9364] Game_1.exe'退出时代码为0(0x0)。

解决方案

这与库没有任何关系,除非该库是使用项目中的源构建的。


如果您查看
/的文档DEBUG链接器选项


" / DEBUG:FASTLINK 选项会保留私有符号信息用于构建可执行文件的各个编译产品。它生成一个有限的PDB,它索引到目标文件中的调试信息和用于构建可执行文件的库
,而不是制作完整的副本。此选项的链接速度可以是完整PDB生成速度的两到四倍,建议您在本地调试并使构建产品可用时使用。当所需的构建产品不可用时,例如当可执行文件部署在另一台计算机上时,此有限的PDB不能用于
进行调试。在开发人员命令提示符中,您可以使用mspdbcmf.exe工具从此有限的PDB生成完整的PDB。在Visual Studio中,
使用Project或Build菜单项生成完整的PDB文件,以便为项目或解决方案创建完整的PDB。 "


因此,使用快速链接选项构建时的调试符号有意不完整。这背后的原因是大型项目中的符号文件创建速度很慢,并且您需要在具有所有构建对象的系统上进行调试。


因此尝试进行完全重建该项目。如果这不起作用,那么进入项目属性并更改:



to:



这将生成完整的符号文件。这也记录在/ DEBUG选项文档中。


"当您指定 / DEBUG 而没有其他选项时,链接器默认为
/ DEBUG:FULL 用于命令行和makefile构建,用于Visual Studio IDE中的发布版本,以及Visual Studio 2015和早期版本中的调试和发布版本。从Visual Studio 2017开始,当您为调试版本指定 / DEBUG 选项时,IDE中的构建系统默认为
/ DEBUG:FASTLINK 。 / p>

我认为如果您编译source.cpp而不构建整个项目本身也可能导致这种情况,这就是为什么有建议首先尝试重建整个项目。


I've installed SFML lib and now when i compiling my project pops error like this:

"path to source.obj"...was built with /DEBUGFASTLINK which requires oject files for debugging.

Subsequent failures will be logged to the Debug pane of the Output window.

In the Output:

'Game_1.exe' (Win32): Loaded 'B:\VISUALSTUDIOPROJECTS\Game_1\Debug\Game_1.exe'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ntdll.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\kernel32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\KernelBase.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'B:\VISUALSTUDIOPROJECTS\Game_1\Debug\sfml-graphics-d-2.dll'. Cannot find or open the PDB file.
'Game_1.exe' (Win32): Loaded 'B:\VISUALSTUDIOPROJECTS\Game_1\Debug\sfml-window-d-2.dll'. Cannot find or open the PDB file.
'Game_1.exe' (Win32): Loaded 'B:\VISUALSTUDIOPROJECTS\Game_1\Debug\sfml-system-d-2.dll'. Cannot find or open the PDB file.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\winmm.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msvcrt.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\user32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\gdi32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\lpk.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\usp10.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\advapi32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\sechost.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\rpcrt4.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\sspicli.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\cryptbase.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msvcp140d.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\vcruntime140d.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ucrtbased.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\api-ms-win-core-localization-l1-2-0.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\api-ms-win-core-processthreads-l1-1-1.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\api-ms-win-core-file-l1-2-0.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\api-ms-win-core-timezone-l1-1-0.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\api-ms-win-core-file-l2-1-0.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\api-ms-win-core-synch-l1-2-0.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\opengl32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\glu32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ddraw.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\dciman32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\setupapi.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\cfgmgr32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\oleaut32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ole32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\devobj.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\dwmapi.dll'. Symbols loaded.
Error: Could not find 'B:\VISUALSTUDIOPROJECTS\Game_1\Game_1\Debug\Source.obj'. Game_1.exe was built with /DEBUG:FASTLINK which requires object files for debugging.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\imm32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msctf.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\uxtheme.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\nvoglv32.dll'. Cannot find or open the PDB file.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\shell32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\shlwapi.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\wtsapi32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\version.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\advapi32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Unloaded 'C:\Windows\SysWOW64\advapi32.dll'
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\gdi32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Unloaded 'C:\Windows\SysWOW64\gdi32.dll'
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\wintrust.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\crypt32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msasn1.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ntmarta.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\Wldap32.dll'. Symbols loaded.
The thread 0x2770 has exited with code 0 (0x0).
The thread 0x2774 has exited with code 0 (0x0).
The thread 0x277c has exited with code 0 (0x0).
The thread 0x2778 has exited with code 0 (0x0).
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\shell32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Unloaded 'C:\Windows\SysWOW64\shell32.dll'
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\nvspcap.dll'. Cannot find or open the PDB file.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\powrprof.dll'. Symbols loaded.
'Game_1.exe' (Win32): Unloaded 'C:\Windows\SysWOW64\powrprof.dll'
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\winsta.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\dinput.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\hid.dll'. Symbols loaded.
'Game_1.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ole32.dll'. Symbols loaded.
'Game_1.exe' (Win32): Unloaded 'C:\Windows\SysWOW64\ole32.dll'
The thread 0x2794 has exited with code 0 (0x0).
The thread 0x2780 has exited with code 0 (0x0).
The thread 0x278c has exited with code 0 (0x0).
The thread 0x2788 has exited with code 0 (0x0).
The thread 0x2798 has exited with code 0 (0x0).
The thread 0x279c has exited with code 0 (0x0).
The program '[9364] Game_1.exe' has exited with code 0 (0x0).

解决方案

This doesn't have anything to do with the library, unless that library was built using the source from your project.

If you look at the documentation for the /DEBUG linker option:

"The /DEBUG:FASTLINK option leaves private symbol information in the individual compilation products used to build the executable. It generates a limited PDB that indexes into the debug information in the object files and libraries used to build the executable instead of making a full copy. This option can link from two to four times as fast as full PDB generation, and is recommended when you are debugging locally and have the build products available. This limited PDB can't be used for debugging when the required build products are not available, such as when the executable is deployed on another computer. In a developer command prompt, you can use the mspdbcmf.exe tool to generate a full PDB from this limited PDB. In Visual Studio, use the Project or Build menu items for generating a full PDB file to create a full PDB for the project or solution. "

So the debug symbols when built with the fast link option are incomplete on purpose. The reason behind this is that the symbol file creation is slow in large projects, and you are expected to be debugging on a system with all of the build objects.

So try doing a full rebuild of the project. If this doesn't work then go into the project properties and change:

to:

This will generate the full symbol file. This is also documented in the /DEBUG option documentation.

"When you specify /DEBUG with no additional options, the linker defaults to /DEBUG:FULL for command line and makefile builds, for release builds in the Visual Studio IDE, and for both debug and release builds in Visual Studio 2015 and earlier versions. Beginning in Visual Studio 2017, the build system in the IDE defaults to /DEBUG:FASTLINK when you specify the /DEBUG option for debug builds."

I think this could also have been caused if you compiled source.cpp without building the whole project itself, which is why there is the suggestion to first try rebuilding the entire project.


这篇关于DEBUGFASTLINK需要目标文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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