build for direct ref