ISTANBUL - Five former journalists of the opposition Cumhuriyet daily, including prominent cartoonist Musa Kart, walked free out of a Turkish prison late Thursday after the country's top appeal court ordered their release.

The five had been serving sentences of less than five years for "aiding and abetting terror groups without being a member".

Lawyer Tora Pekin earlier confirmed the court ruling, speaking to AFP.

The five were among 14 former Cumhuriyet staff, including journalists and executives, sentenced in 2018. Their appeals were rejected by a lower court earlier this year.

They were accused of supporting, through their coverage, three organizations that Turkey views as terrorist groups -- the Kurdistan Workers' Party, the ultra-left Revolutionary People's Liberation Party-Front, and the Gulen movement blamed for the 2016 failed coup.

Behind bars for 142 days, the released journalists were greeted by their supporters and families as outside the prison in Kandira -- in the northwestern city of Kocaeli nearly 150 kilometers (90 miles) from Istanbul-- hours after the top appeals court ordered their release.

The case has sparked criticism over the state of press freedom in Turkey.

Cumhuriyet, the country's oldest daily founded in 1924, is a rare Turkish paper that is not in the hands of a business tycoon, but by an independent foundation.

The daily has often had troubles with government authorities, with its former editor-in-chief Can Dundar fleeing to Germany after being convicted in 2016 over an article alleging that Turkey had supplied weapons to Islamist groups in Syria.