The immigration legislation moving quickly toward a full Senate vote triggered a stand-off Thursday between competing wings of the Republican Party, as conservative members accused their colleagues of greasing the wheels for passage with a "fig leaf" that only claims to address border security.

The debate flared as Senate leaders scramble to hold a vote before the July 4 recess. The legislation gained momentum with lawmakers offering a bipartisan compromise to spend billions on border security while still allowing millions of illegal immigrants to obtain legal status.

Part of the compromise effort was spearheaded Thursday by GOP Sens. John Hoeven of North Dakota and Bob Corker of Tennessee, who pitched an amendment to beef up security. It would double Border Patrol agents on the border, build 700 new miles of fencing and spend billions to deploy additional high-tech tools including drones, radar and seismic monitoring.

"If this amendment passes ... I don't know how anybody could argue that the reason they're not supporting this legislation is because we haven't addressed securing the border," Corker said. "We have addressed that. We've addressed that in spades in this legislation."

But several conservative lawmakers sharply disputed the claim.

More On This...

Sen. Ted Cruz, R-Texas, and others held a press conference shortly before the Corker-Hoeven announcement blasting their proposal.

The senators claimed the Senate was poised to repeat the mistakes of the 1986 immigration overhaul, by putting the promise of border security after other provisions, resulting in a flood of new immigrants.

"What I think the American people want is real border security, not an empty fig leaf. And they want border security first," Cruz said. "If the legalization happened first, the border security never will."

Further, he accused Democrats of seeking a "political victory" by passing a bill through the Senate that the House cannot support.

Some Senate Republicans had gotten behind a proposal that could have addressed those concerns. Sen. John Cornyn, R-Texas, offered an amendment to delay legalization until any border security improvements were proven effective -- but it was sidetracked on a vote of 54-43.

Sens. Jeff Sessions, R-Ala.; David Vitter, R-La.; Chuck Grassley, R-Iowa; and Mike Lee, R-Utah, joined Cruz on the Hill to criticize the latest effort.

But Sen. Marco Rubio, R-Fla., who is considered vital to any immigration deal, publicly endorsed the Corker-Hoeven amendment on Thursday.

"The choice is before us to try to fix this or leave it the way it is. And what we have today is a disaster of epic proportions. We need to fix this, and this is our chance to fix it," he said.

The developments could clear the way for a strong bipartisan vote within a few days to pass the measure that sits atop President Obama's second-term domestic agenda.

The developments came as Democrats who met with House Speaker John Boehner on Wednesday quoted him as saying he expected the House to pass its own version of an immigration bill this summer and Congress to have a final compromise by year's end.

Boehner, R-Ohio, already has said the legislation that goes to the House in the next month or two will not include a pathway to citizenship for immigrants in the United States illegally.

Earlier this week, the Congressional Budget Office jolted lawmakers with an estimate saying that as drafted, the legislation would fail to prevent a steady increase in the future in the number of residents living in the United States illegally.

The estimate appeared to give added credibility to Republicans who have been pressing Democrats to toughen the border security provisions already written into the bill.

"Our whole effort has been to build a bipartisan group that will support the bill," said Hoeven, who's helped develop the deal along with Corker. "That's what this is all about, and it's focused on border security."

It was unclear which other portions of the Senate legislation might be changed. There is pressure from some Republicans to make sure no federal benefits go to immigrants who are in the country illegally, at least until they become citizens.

The underlying legislation already envisions more border agents, additional fencing along the U.S-Mexico border, surveillance drones, a requirement for employers to verify the legal status of potential workers and a biometric system to track foreigners who enter and leave the United States at air and seaports and by land.

Some Republicans have been unwilling to support a bill that grants legal status to immigrants in the country illegally until the government certifies that the border security steps have achieved 90 percent effectiveness in stopping would-be border crossers.

On the other hand, Democrats have opposed Republican proposals to make legalization contingent on success in closing the border to illegal crossings. Under the legislation as drafted, legalization could begin as soon as a security plan was drafted, but a 10-year wait would be required for a green card.

The Associated Press contributed to this report.