some compilation fixes for Linux