如何使用Windows命令行上的命令行将C ++文件编译为SINGLE文件

时间:2011-08-16 09:35:01

标签: .net c++ compiler-construction compilation

  

可能重复:
  Using Visual Studio's 'cl' from a normal command line

我安装了.net框架。

我在发帖前做过搜索。我搜索了compile c++ command line windows

1 个答案:

答案 0 :(得分:1)

对于初学者,您需要一个编译器。

然后你运行编译器,将文件作为参数传递给它,例如cl myfile.cpp(你可能也希望在那里传递一些编译器选项,但哪些依赖于你使用的编译器 - visual studio,或gcc或英特尔等)。

MS为您提供了简短的starter guide,但this one for gcc可能更好,因为它描述了所涉及的所有步骤。