Fix script and packaging of script.