Some build script corrections