On May 8, 1659, the Catalan Revolt came to an end, and on November 7, the Treaty of the Pyrenees was signed between the Spanish and the French monarchies. The agreement notably foresaw a sharing of the principality of Catalonia between the two sovereigns. The crown of France annexed five comarques (corresponding to the two Counts, minus lower Cerdanya and Llívia):