Charlemagne, seeing an opportunity, agreed upon an expedition and crossed the Pyrenees in 778. Near the city of Zaragoza Charlemagne received the homage of Sulayman al-Arabi. However the city, under the leadership of Husayn, closed its gates and refused to submit. Unable to conquer the city by force, Charlemagne decided to retreat. On the way home the rearguard of the army was ambushed and destroyed by Basque forces at the Battle of Roncevaux Pass. "The Song of Roland", a highly romanticized account of this battle, would later become one of the most famous of the Middle Ages. Around 788 Abd ar-Rahman I died and was succeeded by Hisham I. In 792 Hisham proclaimed a jihad, advancing in 793 against the Kingdom of Asturias and Carolingian Septimania (Gothia). They defeated William of Gellone, Count of Toulouse, in battle, but William led an expedition the following year across the eastern Pyrenees. Barcelona, a major city, became a potential target for the Franks in 797, as its governor Zeid rebelled against the Umayyad emir of Córdoba. An army of the emir managed to recapture it in 799, but Louis, at the head of an army, crossed the Pyrenees and besieged the city for seven months until it finally capitulated in 801.