Spanish American wars of independence important change in strategy after three United Provinces campaigns had been defeated in Upper Peru. San Martín's army became the nucleus of the Army of the Andes, which received crucial political and material support in 1816 when Juan Martín de Pueyrredón became Supreme Director of the United Provinces. In January 1817, San Martín was finally ready to advance against the royalists in Chile. Ignoring an injunction from the congress of the Río de la Plata not to move against Chile, San Martín together with General Bernardo O'Higgins Riquelme, later Supreme Director of Chile, led the Army over the Andes in
Jaime Miguel de Guzmán de Avalos y Spinola, Marquis of la Mina, Duke of Palata and Prince of Masa Fernando Castle in Figueras and the reconstruction of the Montjuich fortress. He was buried in the Barceloneta "San Miguel del Puerto Church", an area much decayed along the times but now flourishing again after the 1992 Barcelona Olympic Games. At his death in Barcelona he was replaced by Irish-Spanish General Bernardo O´Connor. Jaime Miguel de Guzmán de Avalos y Spinola, Marquis of la Mina, Duke of Palata and Prince of Masa Jaime de Guzmán y Spinola, II Marquis of la Mina (1690–1767) was a Spanish Army commander and Captain General of Catalonia. He was also the Fifth Count of Pezuela