A 5.2 magnitude earthquake has struck south China's Guangxi region, killing two people and toppling buildings.