【发布时间】:2011-05-29 04:02:34
【问题描述】:
我在 msdn 库中找到了这个示例代码
#include <iostream>
int main()
{
std::cout << "This is a native C++ program." << std::endl;
return 0;
}
来自How to Compile a Native C++ Program From the Command Line 我将此代码存储在 file.cpp 然后我转到命令提示符并输入这个
输出如下:
当前路径> cl /EHsc file.cpp
Microsoft (R) 32 位 C/C++ 优化编译器版本 15.00.30729.01 用于 80x86
版权所有 (C) Microsoft Corporation。保留所有权利。
文件.cpp file.cpp(1) : 致命错误 C1034: iostream: no include path set
我已将路径变量设置为 mirosoft sdk,但我不知道该怎么做。
我尝试了多个文件,如 string.h 和 stdlib.h,但仍然没有运气。
【问题讨论】:
标签: c++ msdn fatal-error