WASHINGTON (Reuters) - Republican presidential candidate Ted Cruz vowed to deport immigrants living illegally in the United States and build a wall to keep others out, sharpening his stance on the issue a week before presidential contests in several southern states.

Republican Presidential candidate Ted Cruz speaks at a rally at the Boys and Girls Club of Truckee Meadows in Reno, Nevada February 22, 2016. REUTERS/James Glover II /Files

Cruz’s comments on the eve of Tuesday’s Nevada caucuses came hours after the public firing of his main spokesman over misleading social media postings involving rival Marco Rubio.

Rubio won endorsements on Monday from prominent Republicans as he sought to become the party’s mainstream alternative to front-runner Donald Trump after Jeb Bush dropped out of the race for the 2016 Republican presidential nomination.

Cruz was asked on Fox News’ “O’Reilly Factor” if he would round up the 12 million illegal aliens in the country, and how.

“Listen, we should enforce the law. How do we enforce the law? Yes, we should deport them. We should build a wall. We should triple the Border Patrol,” Cruz said. “And federal law requires that anyone here illegally that’s apprehended should be deported.”

Asked if he, like real estate tycoon Trump, would go out and look for them, Cruz replied, “Of course you would. That’s what ICE (Immigration and Customs Enforcement) exists for. We have law enforcement that looks for people who are violating the laws.”

The comments marked a shift from last month, when Cruz rejected sending authorities to find immigrants as “police state” tactics.

“I don’t intend to send jackboots to knock on your door and every door in America. That’s not how we enforce the law for any crime,” Mr. Cruz told CNN in an interview on Jan. 10.

Cruz has repeatedly criticized Rubio for having embraced a sweeping immigration reform bill he characterizes as amnesty.

Cruz and other Republican candidates vying to represent their party in the Nov. 8 presidential election have been under pressure to toughen their stance on immigration by Trump’s ferocious rhetoric on the issue.

Trump responded to Cruz’s comments with a trademark Twitter taunt on Tuesday, referring the U.S. senator from Texas’ third-place finish in South Carolina’s primary on Saturday.

“Ted Cruz only talks tough on immigration now because he did so badly in S.C. He is in favor of amnesty and weak on illegal immigration,” Trump said.

The New York billionaire has said he would deport all undocumented immigrants, build a wall and rescind U.S. President Barack Obama’s executive orders on immigration.