fix build bugs