Fix script to build with current setup