build core first