在Visual C++ 2008项目中,构建项目将在输出窗口中显示以下信息:
1>------ Build started: Project: Project1, Configuration: Debug Win32 ------
1>Compiling...
1>main.cpp
1>test1.cpp
1>test2.cpp
1>Generating Code...
1>Linking...
1>LINK : test.exe not found or not built by the last incremental link; performing full link
1>Project1- 0 error(s), 0 warning(s)
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
Run Code Online (Sandbox Code Playgroud)
我怎样才能得到这样的输出:
cl.exe /Od /I "includepath" /D "_UNICODE" /FD /EHsc /RTC1 /MDd /Zc:wchar_t- /Fo"Debug\\" /Fd"Debug\vc90.pdb" /nologo /c /ZI /TP /errorReport:prompt
Run Code Online (Sandbox Code Playgroud)
就像C#项目一样.
打开构建日志记录(菜单工具 → 选项 → 项目和解决方案 → VC++项目设置 → 构建日志记录).然后,您应该在中间文件目录中获取一个构建日志(BuildLog.htm),其中包含您需要的所有信息,包括错误消息.您还将Ctrl在输出窗口中获得一个可单击的链接以显示构建日志.