WASHINGTON (AP) – The U.S. House of Representatives is on track to pass a nearly $612 billion defense policy bill, a measure that usually garners bipartisan support but this year has drawn a veto threat from President Barack Obama, angered a Shiite cleric in Iraq and has Democrats fighting Republicans over federal spending caps.

A vote is expected Friday on the bill to fund the military.

Overall, the House bill authorizes $515 billion in spending for national defense and another $89.2 billion for the emergency war-fighting fund for a total of $604.2 billion. Another $7.7 billion is mandatory defense spending that doesn’t get authorized by Congress. That means the bill would provide the entire $611.9 billion desired by the president, but he still opposes it.

Obama and Democratic lawmakers are against the measure because it ignores automatic spending caps imposed by Congress in 2011 to address federal deficits. The bill increases defense spending by padding the emergency war-fighting fund, which is not affected by the caps. Democrats argue that the GOP wants to ignore spending caps when it comes to funding the military, but wants to adhere to them when it comes to other domestic spending.

The White House is pushing back against a host of provisions in the bill, including one that would make it harder for Obama to close the military prison for terror suspects at Guantanamo Bay, Cuba. On Ukraine, it calls for arming Ukrainian forces fighting Russian-backed separatists, a move the Obama administration has so far resisted.

The administration also opposes measures that aim to bypass the Iraqi government in Baghdad and give money directly to Iraqi Kurdish fighters. That has angered Shiite cleric Muqtada al-Sadr, who threatened to attack U.S. interests if the provision passes.

Mac Thornberry, a Republican representative from Texas, and chairman of the House Armed Services Committee, said Democrats were withholding their support of the defense authorization bill to try to push the revision of the automatic spending cuts currently in place under the Budget Control Act.

“It’s trying to use this and the good it does for our troops to put political pressure on Congress to agree with the president about changes to the Budget Control Act,” Thornberry said.

Rep. Adam Smith of Washington state, the ranking Democrat on the committee, said Congress’s inability to find a way to remove the caps does not justify the use of “gimmicks” to protect the defense spending and shortchange other areas.

The Senate version follows the same approach. The Senate Armed Services Committee voted 22-4 to authorize $523 billion in base funding for the Defense Department and other national security programs and an additional $90.2 billion for the emergency war-fighting fund.

In the House, lawmakers debated 135 amendments to the measure.

The House voted 221-202 to strip an immigration provision opposed by conservatives. The nonbinding provision would have encouraged a Pentagon study on allowing immigrants brought illegally to the country as children to enlist in the military. Conservatives who pushed the vote say the measure would have encouraged amnesty and validated what they consider to be unconstitutional actions Obama has taken to protect millions of immigrants from deportation.