A Tunisian, a Palestinian and four Syrians are getting used to new homes in unfamiliar territory: Uruguay.

The six were all held at Guantanamo Bay for 12 years after they were captured by the US military in Pakistan and Afghanistan. All are suspected militants with ties to al-Qaeda, but they were never charged.

Now they're in Uruguay because the country's president, José Mujica, a former leftist guerrilla, spent time in prison when Uruguay was ruled by a military dictatorship.

"The president believes it's a humanitarian priority to close down the prison in Guantanamo," says Marta Rodriguez, a reporter in the Uruguayan capital of Montevideo. "So it's something he needed to do. It's a commitment."

​Mujica announced back in March that Uruguay would accept the inmates on "humanitarian grounds" in order to help US President Barack Obama fulfill his long-delayed promise to close the prison at Guantanamo.

Mujica has taken pains to treat the former inmates as free men. After their arrival in Uruguay, the six men were taken to a hospital for check-ups. Rodriguez says the government has pledged to support them, help them find jobs and possibly help bring their families to Uruguay. Mujica has even insisted they are free to travel or leave Uruguay if they choose.

That might seem like the natural choice: Uruguay is home to only 300 Muslims, and the Islamic Cultural Organization of Uruguay says it's the only country in South America without a mosque.

But a lawyer for one of the men told a local Uruguayan newspaper that the former inmates were very grateful and plan to integrate into Uruguay. One said he was looking forward to learning how to speak Spanish. Another refugee wrote a letter thanking President Mujica, saying he was happy to leave the "black hole" of the US military prison behind.

He was also looking forward to cheering on the local soccer team.