Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to compile a program in c with a fresh copy of windows? No External Software

Is there any way to compile some Windows API code without installing any development environments to Windows?

Does Windows come with a C Compiler built in that I could just write some code in notepad, and run it through a cmd or a batch file?

like image 533
MutantCoder Avatar asked Feb 09 '15 15:02

MutantCoder


2 Answers

.NET includes a command line compiler for C#. (not exactly what you asked for, but it might suit you.) I believe .NET is preinstalled on modern versions of Windows. Look in the folder \Windows\Microsoft.NET\Framework\v4* and see if you have a file called CSC.EXE. This is the command line compiler for C#.

See

  • "How can I compile a .NET project without having Visual Studio installed?"

  • Working with the C# 2.0 Command Line Compiler

  • Is it possible to install a C# compiler without Visual Studio?

For more information and examples.

You can also get the free version of Visual Studio that supports C++. Download Visual Studio Community 2013

like image 112
Michael Levy Avatar answered Sep 18 '22 00:09

Michael Levy


No version of Windows I am aware of comes with a C compiler.

like image 44
inetknght Avatar answered Sep 21 '22 00:09

inetknght