FASM can output an executable PE directly, but sometimes you want to output an object file for linking with modules in other languages. The following program can be used to link with the C library of the GCC compiler with the following commands:
C:\>fasm hello.asm hello.obj
C:\>gcc hello.obj -o hello.exe
It's almost like magic! :)