Compilation errors fixing