Fix circular reference stuff that was preventing build