Muhammadu Buhari wins a second term as Nigeria's president, after a delayed poll that angered voters and raised political temperatures.