The state funeral of Ghana's longest serving leader, Jerry John Rawlings, has taken place in the capital, Accra.
During a turbulent career, he led two coups before twice being elected president in multiparty polls.
He died in November at the age of 73 of an undisclosed illness, but his funeral was delayed - in part by political squabbling.
The ceremony was held at Independence Square, with numbers attending limited by coronavirus restrictions.
But many Ghanaians headed to the square despite being asked by the government to watch the ceremony on TV in an effort to curb the spread of coronavirus, the BBC's Thomas Naadi reports from Accra.
Mourners were wearing masks and hand sanitiser had been provided but it was proving difficult to practise social distancing, our reporter says.
Prominent mourners included Liberia's President George Weah, Sierra Leonean leader Julius Maada Bio and representatives from the UN and African Union.
President Rawlings contributed to peace efforts in Liberia and Sierra Leone during the civil wars in the 1990s and most recently was an African Union envoy to Somalia. He also led campaigns against malaria across the continent.
'A caring disciplinarian'
Tribute after tribute eulogised the late Ghanaian leader, most describing him as a selfless and committed leader who worked for the common good of his country, our reporter says.
Ghana's President Nana Akufo-Addo described Rawlings as a "charismatic and fearless leader", reports the AFP news agency.
His widow Nana Konadu Agyemang-Rawlings was quoted as saying: "Your gift of sharing knew no bounds. You never hesitated to help in the passing of laws to protect the vulnerable in society. Jerry, I know that God created us for each other."
Earlier, hundreds of people went to pay their respects to the former president as his body lay in state for three days.
Many of them remember him as a disciplinarian but also as a leader who cared about ordinary people, our correspondent says.
After the funeral, Rawlings was laid to rest at the military cemetery in Accra.
Our correspondent reports that some people wanted him to be buried in his home region of Volta.
It is not the only row to dog events - the funeral was originally scheduled for 23 December.
The National Democratic Congress (NDC), a party Rawlings founded and which is now in opposition, wanted more involvement in organising the state funeral, which led to the delay.
One party leader even threatened to "steal his remains" following the funeral so that the party could bury him again.
Who was Jerry Rawlings?
The son of a Scottish farmer and a Ghanaian mother, Rawlings entered the Ghana Air Force, graduating in 1969.
A decade later, as a senior officer in the air force, he overthrew a military government, handing over power to a civilian leader.
He oversaw the execution of several former heads of state and army generals for corruption, but expressed some regret about the killings. Later the execution by firing squad of Supreme Court judges also left a stain on his legacy.
In 1981, he led a second coup and was the head of a military junta until introducing multiparty elections in 1992, when he was first elected president.
This ushered in a long period of political stability.
In 2001, he stepped down after serving two terms but continued to wield a strong influence in the country.
In later years, Rawlings campaigned for African nations to have their international debts written off.