re-write for building with local manifest