Fix build files to die on error