Fixed compile issues on some Linux platforms