Added additional argument for building onepcm and adapted test to new return code of scripts