What gave was the usual brilliance of Brussels. The generals were plotting to kill him on national TV as they usually did, but around 2005-6 EU leaders started pearl clutching about religious freedom and how Turkey would never enter EU if not human rights or similar bullshit - so Turkey is still outside of EU, no chance of getting in, but they enjoy serious regress in freedoms, Islamization and a monkey with a wrench in charge of their economy.
Turkey always had a demographic problem, just like Iran does, it’s not in the EU because it could not resolve its own demographic problem not that it’s demographic problem was somehow due to the EU closing the door on Turkey’s membership.
Of course the EU votes would go to Erdogan - the people that moved to Germany were from his power base demographic.
The Islamic Revolution didn’t succeed power by chance, whilst the Shah was opposed by many factions form secular communists to religious fanatics the reason why the mullahs came on top was because the majority of the population was a bunch of illiterate religious nut jobs.
This is also why Turkey has regressed so much, the secular metropolitan elite that followed Ataturk’s legacy was and is out numbered by the rural masses at least 3 to 1. At some point something had to give which is now why you have decades of Erdogan.