Benjamin Kramer and Joerg Sonnenberger for their input and fixes.
This contains many improvements, primarily better C++ support, an integrated assembler for x86 and support for -pg.