Fixed some compilation errors on Linux