build script: fixes