build ordering and clustering fixes