Adapted various POSIX headers to Linux/ARM.

Slowly working my way towards committing/upstreaming all the LDC/ARM stuff.

There are probably more pull requests to come.