By 1090, a new state was created under Count Henrique. It was called Portucale. Portus Cale referred to either the port town of Cale (Gaia today) or Cale and its neighboring town. Today “Portus” is known as Porto.
Galicia is a province of Northwestern Spain, and is tied to Portugals origins. Portuguese is derived from Luso-Gailico, a corruption of common Latin. Today, the Galician language is very similar to modern Portuguese, and in the 11th century the Galicia and Northern Portugal formed the fragile frontier of Europe with Moorish forces.
When D. Henrique died, his wife took the county of Portucale. Their son, D. Afonso Henriques called his mother out in 1128, just outside the capital Guimaraes at the Battle of Sao Mamede, and replaced her as ruler. At this point Guimarães was the capital of Portugal, a heavily fortified city north of Porto. The Minho River was then, as it is today, on the border with Galicia, and the Moors held the lands south of the Mondego River. Today, Guimarães is still one of the country's most historic cities, its medieval streets are filled with ancient monuments such as its castle, with eight 92 foot towers, built in the 10th century to protect the population from attacks by the Moors.
Next, D. Afonso pushed the Moors back beyond the Mondego River expanding his county. In 1139 D. Afonso won a legendary battle at Ourique, defeating five Caliphs and declaring his nations independence. By 1143 the warrior kings new nation had won Papal recognition. By 1147 he led his small army to victory, taking the city of Lisbon. Portugal was a nation.