WASHINGTON – House and Senate negotiators announced an agreement Tuesday on a $612 billion defense policy bill that President Obama has threatened to veto.

The bill gives Obama the increase in funding he requested, but he’s unhappy with the way lawmakers did it. The legislation authorizes an increase in defense spending by padding a war-fighting account that’s not subject to limits Congress has imposed on military and domestic spending.

The measure would retain current restrictions on transferring detainees out of the U.S. military prison at Guantanamo Bay, Cuba, that have been in place since 2009 and presses the White House to send Congress a plan to close the facility.

“There is still no plan on what to do and how to do it with the detainees at Guantanamo Bay,” said Sen. John McCain, R-Ariz., chairman of the Senate Armed Services Committee. “If the administration complains about the provisions on Guantanamo, then it’s their fault because they never come forward with a plan.”

Among other things, the massive bill offers a slight pay increase to service members and authorizes funds for ships, aircraft and weapon systems. It calls for government matching funds to new 401(k)-type plans, replacing a system that doesn’t leave retiring troops with anything unless they serve 20 years.

It authorizes money to provide weapons for Ukraine forces fighting Russian-backed rebels.

McCain and Rep. Mac Thornberry, R-Texas, chairman of the House Armed Services Committee, both acknowledged that the legislation does not solve the spending problems. But McCain insisted that is a budget fight that should not be fought on his legislation.

“I don’t think we can wait till December to pass a defense authorization bill,” said Thornberry. “I’m hopeful that we can pass this bill, and I’m hopeful that the president will agree to it.”

He said the House would vote on the bill Thursday. The Senate is scheduled to vote on Wednesday.

The defense policy bill is one of the few bipartisan measures that Congress has cleared and the president has signed into law for more than a half century. But this year’s bill faces a legitimate threat of a presidential veto.