runproject: open tmpf when needed