DAKAR/RIO DE JANEIRO—For five centuries, raw materials have flowed out of Africa and Brazil at low cost to be used as inputs elsewhere—often...