The EGCS-Ming32 compiler is almost as easy to setup as the Cygnus c compiler but has the advantage that is also includes GNU Fortran 77 (under the executable name of g77). It also supposedly does not require any run time DLLs to be distributed with executables. Please note that this is not the same as the MingW32 compiler but is a hybrid between the EGCS compiler and MingW32 compiler(?)
(Note: when adding the environment variables, the trailing slash "\" at the end of the line is very important. Miss it out and you can be in a world of pain. The same thing goes if you have a space at the end of the line as this also stuffs things up. Also, if you have problems with it not using the environment variable properly, try changing the case of the environment variable.
Information on the package is available at:
For C, you can also build a "Hello World" program and compile it to test things out.
#include <stdio.h> int main(void) { printf("Hello, world!\n"); return 0; }
Build it using the command gcc hello.c -o hello.exe
For Fortran, you can build a "Hello World" program with source code filename as SMTEST.F and compile it to test things out.
PROGRAM SMTEST DO 10 I=1, 10 PRINT *, 'Hello World #', I 10 CONTINUE END
Build it using the command g77 -o SMTEST.EXE SMTEST.FOR