* Erdogan had warned square would be cleared
* "Tayyip, resign," protesters chant
* Ruling party rally set for Sunday
* Labour confederation calls national strike for Monday
Thousands of people took to the streets of Istanbul overnight on Sunday, erecting barricades and starting bonfires, after riot police firing teargas and water cannon stormed a park at the centre of two weeks of anti-government unrest.
Lines of police backed by armoured vehicles sealed off Taksim Square in the centre of the city as officers raided the adjoining Gezi Park late on Saturday, where protesters had been camped in a ramshackle settlement of tents.
Prime Minister Tayyip Erdogan had warned hours earlier that security forces would clear the square, the centre of more than two weeks of fierce anti-government protests that spread to cities across the country, unless the demonstrators withdrew before a ruling party rally in Istanbul on Sunday.
"We have our Istanbul rally tomorrow. I say it clearly: Taksim Square must be evacuated, otherwise this country's security forces know how to evacuate it," he told tens of thousands of flag-waving supporters at a rally in Ankara.
Protesters took to the streets in several neighbourhoods across Istanbul following the raid on Gezi Park, ripping up metal fences, paving stones and advertising hoardings to build barricades and lighting bonfires of trash in the streets.
Some chanted, "Tayyip, resign."
Local television footage showed groups of demonstrators blocking a main highway to Ataturk airport on the western edge of the city, while to the east, several hundred walked towards a main bridge crossing the Bosphorus waterway towards Taksim.
Thousands more rallied in the working-class Gazi neighbourhood, which saw heavy clashes with police in the 1990s, while protesters also gathered in Ankara around the central Kugulu Park, including opposition MPs who sat in the streets in an effort to prevent the police from firing teargas.
A main public-sector union confederation, KESK, which has some 240,000 members, said it would call a national strike for Monday, while a second union grouping said it was holding an emergency meeting to decide whether to join the action.
"One million people to Taksim" - a call for more anti-government demonstrations later on Sunday - was a top-trending hashtag on Twitter.
"The police brutality aims at clearing the streets of Istanbul to make way for Erdogan's meeting tomorrow," said Oguz Kaan Salici, Istanbul president of the main opposition People's Republican Party.
"Yet it will backfire. People feel betrayed."
CLOUDS OF TEARGAS
A similar police crackdown on peaceful campaigners in Gezi Park two weeks ago provoked an unprecedented wave of protest against Erdogan, drawing in secularists, nationalists, professionals, trade unionists and students who took to the streets in protest at what they see as his autocratic style.
The unrest, in which police fired teargas and water cannon at stone-throwing protesters night after night in cities including Istanbul and Ankara, left four people dead and about 5,000 injured, according to the Turkish Medical Association.
Panicked protesters fled into an upscale hotel at the back of Gezi Park during Saturday night's raid, several of them vomiting, as clouds of teargas and blasts from percussion bombs - designed to create confusion rather than injure - engulfed the park.
"We tried to flee and the police pursued us. It was like war," Claudia Roth, co-chair of Germany's Greens party, who had gone to Gezi Park to show her support, told Reuters.
The Gezi Park protesters, who oppose government plans to build a replica Ottoman-era barracks there, had defied repeated calls to leave but had started to reduce their presence in the park after meetings with Erdogan and the local authorities.
"This is unbelievable. They had already taken out political banners and were reducing to a symbolic presence in the park," Koray Caliskan, a political scientist at Bosphorus University, told Reuters from the edge of Gezi Park.
Erdogan told protesters on Thursday that he would put the Gezi Park plans on hold until a court rules on them. It was a softer stance after two weeks in which he called protesters "riff-raff" and said the plans would go ahead regardless.
But at the first of two rallies this weekend by his ruling AK Party, he reverted to a defiant tone, telling supporters on the outskirts of Ankara that he would crush his opponents in elections next year.
The police intervention so soon after Erdogan spoke took many by surprise on a busy Saturday night around Taksim, one of Istanbul's main social hubs, not least after President Abdullah Gul, who has struck a more conciliatory tone than Erdogan, said earlier on Saturday that talks were progressing well.
Erdogan has long been Turkey's most popular politician, his AK Party winning three successive election victories, each time with a larger share of the vote, but his critics complain of increasing authoritarianism.
He has said the AK Party rallies in Ankara and Istanbul are meant to kick off campaigning for local elections next year and are not related to the protests, but they are widely seen as a show of strength in the face of the demonstrations.