Merge pull request #3 from MichaelSchoebel/fpc-linux

Several changes to compile with FPC on Linux
Make this branch compile with Delphi XE2 again