KYIV—Thousands of Ukrainian protesters on Monday blocked entrances to the government building and called for the ouster of the prime minister and his cabinet, as anger at the president’s decision to ditch a deal for closer ties with the European Union gripped other parts of the country and threatened his rule.

The besieging of the building follows a huge rally in the capital by hundreds of thousands Ukrainians on Sunday. The rally was mostly peaceful, until a group of protesters tried to storm President Viktor Yanukovych’s office. After hours of scuffles, police chased protesters away with tear gas and truncheons.

It was a violent police action against protesters early Saturday that galvanized the latest round of protests whose aim is to bring down the president and his government.

At least three lawmakers of the governing Party of Regions have quit in protest, and the opposition wants to oust the Cabinet of Prime Minister Mykola Azarov during a confidence vote in Parliament on Tuesday. But the opposition, which now controls some 170 seats, would need 226 votes in the 450-seat Parliament to oust the government.

Azarov’s spokesman Vitaly Lukyanenko on Monday said the government was not planning to impose a state of emergency. He would not say whether the prime minister and his ministers were able to enter the Cabinet building, according to the Interfax news agency. Lukyanenko did not pick up the phone when The Associated Press tried to reach him.

In parts of western Ukraine, where most speak Ukrainian and lean toward the EU, some local officials seem to be in open revolt.

The mayor of Lviv called on the people there to protest and warned that police would take off their uniforms and defend the city if the central government sends reinforcements. Scores of protesters from Lviv and elsewhere in western Ukraine headed to Kyiv by train and cars to take part in the rallies.

“Yanukovych is — both, as president and as a politician — done,” said Andreas Umland, assistant professor of European studies at the Kyiv Mohyla Academy.

In Kyiv, thousands returned to Independence Square, where several hundred core protesters had spent the night in a tent camp. Hundreds of others were holding ground inside the Kyiv city hall and a labour union building, where they had barricaded themselves Sunday.

“Our goal is to oust the authorities through strikes,” said Serhiy Korchinsky, 35, an engineer from Lviv who spent the night in the protest camp. “The government will be paralyzed until Yanukovych and Azarov resign.”

Protests have been held daily in Kyiv since Yanukovych backed away from an agreement that would have established free trade and deepened political co-operation between Ukraine and the EU. He justified the decision by saying that Ukraine couldn’t afford to break trade ties with Russia.