Wealthy governments have been accused of promoting fossil fuel development in Africa at the expense of clean energy.