Because it lasted so long, many combatants were involved in the Reconquista. An Umayyad emirate was established in Spain in the 8th century. The rulers of Asturias were the first to try to wrest Spain from the Moors. Charlemagne captured Barcelona. The Christian kingdoms of Castile and León also fought, as did the kingdoms of Aragon and Navarre. Almoravids and Almohads successively followed the Umayyads and continued the war.