Robert Mugabe, the former autocratic leader of Zimbabwe who ruled with an iron fist for nearly four decades, has died at 95. Mugabe remained one of the continent’s most divisive figures until the end. He was accused of orchestrating human rights abuses against impoverished black Zimbabweans, white farmers and thousands of LGBTQ people during his 37-year rule. Critics say he amassed vast wealth as the resource-rich southern African nation spiraled into poverty. His death comes nearly two years after he was forced to resign as president in the wake of a sudden military takeover. Zimbabwe President Emmerson Dambudzo Mnangagwa shared condolences on Twitter on Friday:

It is with the utmost sadness that I announce the passing on of Zimbabwe's founding father and former President, Cde Robert Mugabe (1/2) — President of Zimbabwe (@edmnangagwa) September 6, 2019

Cde Mugabe was an icon of liberation, a pan-Africanist who dedicated his life to the emancipation and empowerment of his people. His contribution to the history of our nation and continent will never be forgotten. May his soul rest in eternal peace (2/2) — President of Zimbabwe (@edmnangagwa) September 6, 2019

JEKESAI NJIKIZANA via Getty Images Robert Mugabe, president of Zimbabwe until November 2017, had ruled for nearly four decades.

The former freedom fighter came to power when white-minority rule ended in 1980, and he said he intended to reign for life. He served as prime minister until 1987, then as president until he was ousted in November 2017.

Howard Burditt/Reuters Mugabe's second marriage, to Grace Marufu, in 1996 received the blessing of Pope John Paul II.

Early Life Mugabe was born in the Zvimba district of Southern Rhodesia (now Zimbabwe), on Feb. 21, 1924 ― four months after Britain colonized the territory. He gained the first of seven degrees in 1951 and embarked on a career as a schoolteacher. In 1958, Mugabe met his future wife, Sarah “Sally” Hayfron, when they were both teaching in Ghana, where he saw firsthand the fruits of independence in the former British colony. He was inspired to become a Marxist. When Mugabe returned to Southern Rhodesia in 1960, he found that the colonial government had displaced thousands of black families. That year, he advocated striving toward independence, espousing Marxist ideals. He was elected public secretary of the National Democratic Party, set up to push for the end to white-minority rule and achieve more rights for black people, including abolishing laws that bolstered racial discrimination and segregation. Mugabe married Hayfron in 1961, the year he led the launch of a deadly guerrilla war, after the British banned the NDP. In 1963, he founded the Zimbabwe African National Union, another resistance movement, in the East African country of Tanzania ― which the British quickly outlawed because of its opposition to white rule. The following year, police arrested Mugabe in Southern Rhodesia for making a “subversive speech” and imprisoned him for 10 years. When his only child with Hayfron, Nhamodzenyika, died of malaria at age 3 in 1966, authorities refused to allow Mugabe to attend the boy’s funeral.

ALEXANDER JOE via Getty Images Mugabe leads a pre-election rally in the capital city of Harare on March 22, 2008.

Political Career Mugabe continued to operate the guerrilla campaign from behind bars. He was released from jail in 1974 and continued the fight for independence until Britain agreed in 1979 to monitor the changeover to black majority rule. Southern Rhodesia became the independent Republic of Zimbabwe in 1980, when the Mugabe-led Zimbabwe African National Union - Patriotic Front was elected to power and he became prime minister. Mugabe and Britain’s then-foreign secretary, Lord Carrington, were jointly nominated for the Nobel Peace Prize that year. Two years later, Mugabe sent his North Korea-trained Fifth Brigade to the province of Matabeleland to crush a rebellion started mainly by members of the minority Ndebele tribe. More than 20,000 people were killed in the ethnic cleansing, known as the “Gukurahundi” suppression, according to the Catholic Commission for Justice and Peace. The suppression ended when ZANU-PF and the Zimbabwe African People’s Union signed the Unity Accord, forming a united nationalist party, in 1987 ― the year that Mugabe assumed the presidency after the prime ministerial role was abolished. Mugabe went on to win every subsequent election and ruled Zimbabwe until November 2017. But there were repeated claims of vote-rigging that resulted in sometimes deadly protests. In the late 1980s, Mugabe met Grace Marufu, who would become his mistress. They were married in 1996 in a lavish ceremony attended by thousands of guests, including Nelson Mandela, who was the President of South Africa at the time. Mugabe is survived by Grace and their three children.

Belal Khaled/NurPhoto via Getty Images President Emmerson Mnangagwa greets Zimbabweans during his inauguration ceremony on Nov. 24, 2017.