Nils Weller's C compiler


nwcc is a C compiler for Unix systems that I wrote in my freetime, for fun and to prove to myself that I could. I started the project in August 2003, but because I had a job and a life and a few other hobby code projects, it took me until autumn 2005 to make it work with various constructs of the C language.

The code of nwcc is written in C, is currently around 80,000 lines in size (this includes all backends), and I've released it under the (revised) BSD license. It works with Linux/Mac OS X/FreeBSD/OpenBSD/NetBSD/Solaris on 80x86, Linux/Mac OS X/FreeBSD/OpenBSD on AMD64, Solaris/Linux on SPARC, AIX/Linux on PowerPC, and IRIX on MIPS hardware. Apart from full C89 support, nwcc also understands lots of C99 and GNU C features, and can be used as a drop-in replacement for gcc in many cases. Cross-compilation and PIC code for shared libraries are also supported.

Only some large applications can be compiled with nwcc (i.e. those that have received explicit debugging - gcc, Apache, PHP, PostgreSQL), but many other smaller applications are also known to work - Such as bash, xterm, vim, wget, gxemul, lynx, lsof, strace, zsh, GNU less/tar/make, nasm, and others.

Feature-wise, there are still a lot of things missing in nwcc:

nwcc © Nils Weller 2003 - 2011 Valid XHTML 1.0 Strict SourceForge Logo