Fixed errors when trying to compile with gcc