Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to compile C programming in Windows 7? [closed]

Tags:

c

windows-7

I am looking for free tools to compile C programs on Windows 7. I've always compiled C code on Ubuntu using gcc in the past. So, how can I compile C code on Windows 7? Please teach me. :)

like image 886
Mohd Isa Avatar asked Apr 17 '11 05:04

Mohd Isa


2 Answers

MinGW uses a fairly old version of GCC (3.4.5, I believe), and hasn't been updated in a while. If you're already comfortable with the GCC toolset and just looking to get your feet wet in Windows programming, this may be a good option for you. There are lots of great IDEs available that use this compiler.

Edit: Apparently I was wrong; that's what I get for talking about something I know very little about. Tauran points out that there is a project that aims to provide the MinGW toolkit with the current version of GCC. You can download it from their website.


However, I'm not sure that I can recommend it for serious Windows development. If you're not a idealistic fanboy who can't stomach the notion of ever using Microsoft software, I highly recommend investigating Visual Studio, which comes bundled with Microsoft's C/C++ compiler. The Express version (which includes the same compiler as all the paid-for editions) is absolutely free for download. In addition to the compiler, Visual Studio also provides a world-class IDE that makes developing Windows-specific applications much easier. Yes, detractors will ramble on about the fact that it's not fully standards-compliant, but such is the world of writing Windows applications. They're never going to be truly portable once you include windows.h, so most of the idealistic dedication just ends up being a waste of time.

like image 172
Cody Gray Avatar answered Sep 29 '22 19:09

Cody Gray


Microsoft Visual Studio Express

It's a full IDE, with powerful debugging tools, syntax highlighting, etc.

like image 32
joce Avatar answered Sep 29 '22 19:09

joce