Yoweri Museveni has won a record seventh term in elections after promising that the fledgling oil sector will boost the economy.