Fixing package problems and possible compilation errors