Repackaging and cleanup