Turkish President Recep Tayyip Erdogan condemned the Egyptian government late Monday following the abrupt death of former President Mohamed Morsi in court, calling Morsi a “martyr” and his death an “execution” by the “murderer” President Abdel Fattah al-Sisi.

Morsi died during a hearing Monday of a heart attack following an impassioned statement to the court. Egypt’s judiciary had already sentenced Morsi to over 45 years in prison on charges of “leading an outlawed group, detention and torture of anti-government protesters and leaking state secrets,” according to the BBC. At the time of his death, he was speaking in defense against charges of espionage for the terrorist organization Hamas.

Egyptian media confirmed Tuesday morning that Morsi died of a heart attack and the government organized a quiet burial for him early Tuesday, reportedly against the wishes of his family who requested a public funeral.

Morsi became Egypt’s first democratically elected president in 2012 after the Arab Spring protests that swept the region that year toppled longtime dictator Hosni Mubarak. Morsi is a member of the Muslim Brotherhood global Islamist organization, which Sisi outlawed after removing Morsi from office in 2013.

Erdogan, the head of Turkey’s Islamist Justice and Development Party (AKP), is a longtime public supporter of the Muslim Brotherhood.

“I, first of all, I wish God’s mercy for our martyred brother Morsi,” Erdoğan said on Monday. “The West has always been silent in the face of these executions by Sissi. EU member states forbidding execution unfortunately accepted an invitation by this murderer Sissi to attend a meeting in Egypt.”

The European Union recently launched an initiative to expand cooperation with Sisi’s Egypt, infuriating Erdogan. Erdogan has also made his distaste for Sisi, who rose to power promising a firm hand against Islamists, evident for years. The Turkish government has accused its Egyptian counterpart of supporting terrorism for his ties to Kurdish groups – an accusation that Sisi’s government returned. Ankara has also set about building a rival Islamic university to the premier institution in the world, Egypt’s Al-Azhar University, after Erdogan supporters accused Sisi of “sabotaging” Islamic education.

“The late Morsi was tried and sentenced to death by the coup courts and drew his last breath in a courtroom again, which is a symbol of the years of long persecution against him and his people,” Erdogan stated, according to Turkey’s state Anadolu news agency. “The oppressors may make attempts against the lives of the oppressed and may even lead them to be martyred, but they can never harm the glory of their struggle.”

“For us, Morsi is a martyr for his cause. History will never forget those tyrants who put him in prison, threatened him with death and led to his martyrdom,” he concluded, reportedly adding that “all Muslims will remember the late Morsi for the honorable struggle he carried out until his last breath.”

The Turkish Foreign Ministry also issued a statement lauding Morsi as “an exceptional person in his country’s struggle for democracy” and several Erdogan officials, including the chairman of the AKP and Foreign Minister Mevlüt Çavuşoğlu, hailed Morsi as a “martyr” as Erdogan did.

Erdogan has ordered nationwide funeral rites in absentia in Morsi’s honor for Tuesday, which the president will reportedly attend. The Islamic funeral services will span “from Jerusalem to Istanbul” according to an AKP spokesman.

Morsi’s shocking death occurred just minutes after he had addressed the court from the glass cage that the Egyptian government kept him when not in prison. The Associated Press (AP) reported Monday that Morsi had warned that he would reveal “many secrets” of those in power in an extended, impassioned commentary to the court, after which he collapsed and failed to recover.

Erdogan’s claim that Morsi’s death was a homicide echo the statement issued by the official leadership of the Muslim Brotherhood, which declared the death a “full-fledged murder.”

“The authorities of the treacherous military coup bear full responsibility for his deliberate murder,” an Arabic-language statement on the group’s website read. “The Muslim Brotherhood demands that an international investigation be opened into this event by a professional non-coup medical committee to explain the true cause of death and to reveal the report to the world.”

“The Muslim Brotherhood also calls on all the world’s human rights and human rights organizations – including the United Nations – to act to stop the slow murder by medical negligence committed against thousands of detainees held in coup prisons,” the statement concluded.

At least two human rights groups – Amnesty International and Human Rights Watch – have heeded the Muslim Brotherhood’s call.

Sarah Leah Whitson, Middle East director with Human Rights Watch, said the death was due to the Sisi government’s “failure to allow him adequate medical care, much less family visits.” Amnesty International, in turn, demanded an “immediate investigation” into the matter and accused Egypt of having “an appalling track record of detaining prisoners in prolonged solitary confinement and in dire conditions as well as subjecting prisoners to torture and other ill-treatment.”

Sisi’s government labeled the Muslim Brotherhood a banned terrorist organization shortly after he took power. Saudi Arabia, the United Arab Emirates, and Russia have also designated the Muslim Brotherhood a terrorist organization. In the United States, the Trump administration has publically considered doing the same given the group’s ties to organizations like Hamas.

Follow Frances Martel on Facebook and Twitter.