CAPE TOWN (Reuters) - Veteran South African anti-apartheid activist Ahmed Kathrada, who was sentenced to life imprisonment alongside Nelson Mandela and went on to be an open critic of President Jacob Zuma, died on Tuesday aged 87.

Affectionately known as “Uncle Kathy,” the liberation struggle stalwart who spent 26-years in prison under the apartheid government, was hospitalized in Johannesburg this month after surgery to relieve blood clotting on the brain.

Kathrada’s foundation said his condition had deteriorated rapidly with pneumonia affecting both lungs. It announced his death at 6 a.m. local time.

Siphiwe Sibeko / Reuters Veteran South African anti-apartheid activist Ahmed Kathrada died on Tuesday at the age of 87.

President Jacob Zuma said Kathrada would be honored at an official state funeral and flags at government offices would fly at half-mast until then.

Nobel Peace Prize winner Archbishop Desmond Tutu said Kathrada helped inspire the world’s confidence in South Africa’s long battle against white-minority rule.

“May Ahmed rest in peace and rise in glory,” Tutu said in a statement. “May he rejoice in many heavenly cups of hot chocolate with his old friends and comrades.”

Kathrada, who dedicated his life to fighting the racial injustice of white-minority rule, was also one of the most senior African National Congress (ANC) leaders to criticize Zuma as allegations of government corruption mounted.

Last year, Kathrada wrote an open letter calling on Zuma to resign after a series of scandals, from using taxpayers money to upgrade his rural home to destabilizing financial markets by flip-flopping on cabinet appointments.

“I am not a political analyst, but I am now driven to ask: Dear Comrade President, don’t you think your continued stay as president will only serve to deepen the crisis of confidence in the government of the country?” Kathrada said then.

POOL New / Reuters Kathrada spoke at the funeral of former South African President Nelson Mandela in 2013.

Born to immigrant Indian parents in the small town of Schweizer-Reneke in the North West province just before the Great Depression in 1929, Kathrada became involved in politics at the age of 12 when he distributed leaflets for the Young Communist League of South Africa.

Following decades of activism, Kathrada was sentenced to life imprisonment and hard labor in 1964, together with seven other ANC luminaries such as Mandela, Walter Sisulu and Govan Mbeki, after a guilty verdict during the Rivonia treason trial.

Jailed at the age of 34, Kathrada spent the next 18 years at the maximum security section on apartheid’s most notorious prison, Robben Island, a few miles offshore from Cape Town.

He was moved to Pollsmoor prison in 1982 and was released from jail on 15 October 1989 at the age of 60, having spent just over 26 years in jail.