1. Technology

List of Free C Compilers

More C Compilers than you can ever use on many platforms


Paul Thomas/Stockbyte/Getty Images

If you're interested in learning to program in C you'll find this list of C Compilers handy. You'll need one for The C Programming tutorials we have on site. Most of these compilers do C++ and C. Just rename the files to have .C extensions.

  • Microsoft Visual Studio Express for Windows Desktop. Not everyone likes Microsoft but there's no denying that they do provide very good code with an excellent IDE. It needs .NET and Windows 7 or later though you can compile for win 32, (no MFC) with the C++ part as well as VB.NET/C#. It requires free registration.

  • Open Watcom. Getting a bit long in the tooth and the IDE isn't great but runs on Windows 2000 (probably 98) as well as newer Windows.

  • GCC. The classic open source C compiler for Linux and many other operating systems (and Windows under Cygwin or Ming). A project that has been around forever. Excellent open source quality software. It doesn't come with an IDE (which are generally platform dependent) but there are loads out there eg MonoDevelop on Linux.

  • Digital Mars C/C++ Compiler. Their IDE costs ($42.55) but the Basic C/C++ Win 32 compiler is free.

  • Xcode. This is for Apple Macs and is their version of GCC but purely for Apple's own Mac OS Operating System. It has excellent documentation and SDKs for Mac and iPhone. If you have a Mac this is what you use.

  • Tiny C - Compiler. TinyCC (aka TCC) is a small fast C compiler that is meant to be self-relying: you do not need an external assembler or linker because TCC does that for you. With the aid of another library it can be used as a backend code generator. TCC compiles so fast that even for big projects Makefiles may not be necessary.

  • Portable C Compiler. This was developed from one of the earliest C Compilers and at the start of the 80s most c compilers were based on it. Portability was designed into it from the start in contrast to Dennis Ritchie's C compiler which was very hardware dependent. It's now being developed to be C99 compatible.

  • Failsafe C. A Japanese project from the Research Team for Software Security at the Research Center for Information Security (RCIS), National Institute of Advanced Industrial Science and Technology (AIST), JAPAN, this version of C for Linux supports over 500 functions (not C99 or Widechar). It provides complete protection against memory block over-boundary accesses making it as safe as Java and C#.

  • Pelles C is a free development kit for Windows and Windows Mobile containing an optimizing C compiler, a macro assembler, a linker, a resource compiler, a message compiler, a make utility and install builders for both Windows and Windows Mobile. It also has an IDE with project management, debugger, source code editor and resource editors for dialogs, menus, string tables, accelerator tables, bitmaps, icons, cursors, animated cursors, animation videos (AVI's without sound), versions and XP manifests.

  • CC65 is an open source cross development package for 65(C)02 systems, including a powerful macro assembler, a C compiler, linker, librarian and several other tools. It includes support for Commodore C64, the GEOS operating system for the Commodore C64, the Commodore C128, the Commodore C16, C116 and Plus/4, the Commodore P500, the Commodore 600/700 family of computers, the Apple ][, the Atari 8bit machines, the Oric Atmos, the Nintendo Entertainment System (NES), the Supervision Game Console and the Atari Lynx Console

  • lcc is a retargetable compiler for Standard C. It generates code for the ALPHA, SPARC, MIPS R3000, and Intel x86 and its successors. It's been compiling production programs since 1988 and used by hundreds of C programmers. Addison-Wesley published a book about it, documenting how it works back in 1995 that you can still buy.

  • SDCC is also retargettable, and optimizing ANSI - C compiler targeting the Intel 8051, Maxim 80DS390, Zilog Z80 and the Motorola 68HC08 based MCUs. It has the ability to add inline assembler code anywhere in a function, as well reporting on the complexity of a function to help decide what should be re-written in assembler and comes with the source level debugger SDCDB.

  • Borland C++ 5.5 is only a 8.5 MB download. It includes the compiler bcc32, 32 bit linker (tlink32), Borland Resource Compiler / Binder (brc32, brcc32), C++ Win32 Preprocessor (cpp32) and a few other utilities for importing definitions from libraries, and about dlls, exes plus a .hlp file.

  • nesC is an extension to the C programming language designed to embody the structuring concepts and execution model of TinyOS. TinyOS is an event-driven operating system designed for sensor network nodes that have very limited resources (e.g., 8K bytes of program memory, 512 bytes of RAM).

  • Cc386 is a free Win 32 C compiler, that supports C99 (or will do soon). This has been put together by David Lindauer over 8 years and includes the source code for the compiler and tools. It also includes an IDE which provides compilation, editing and debugging. A very impress achievement for one individual.

  • SubC is a fast, simple public domain compiler for a clean subset of the C programming language on Linux, FreeBSD and Windows platforms. It can compile itself and is the subject of a book "PRACTICAL COMPILER CONSTRUCTION" explaining the anatomy of a C Compiler.

Now you've got your compiler you are ready for the C Programming tutorials!

  1. About.com
  2. Technology
  3. C / C++ / C#
  4. Tools, E-Books and Utilities
  5. List of Free C Compilers and IDEs

©2014 About.com. All rights reserved.