issue #2347: Compiled ok for android, marmalade and nacl, windows needs to be tested too.
Fixing errors on windows.