The US Senate has completed congressional approval of a sweeping $1.3tn (£921bn) package to fund the government until September.

Senators passed the 2,232-page bill in a 65-32 vote early on Friday, hours after the House backed it.

President Donald Trump is now expected to sign the bill into law ahead of a Friday midnight deadline.

This would fund the federal government until 30 September, and avert another government shutdown.

The US had already had two government shutdowns this year.

The vote in the Senate early on Friday caps weeks of haggling over a number of key issues dividing lawmakers.

But the bill does not address the fate of young immigrants brought illegally to the US by their parents, a group who were protected by the Deferred Action for Childhood Arrivals (Daca) programme until President Trump ended it in September.

'The Wall'
Republican Speaker of the House Paul Ryan celebrated the package as a means to enact President Trump's policy positions.

"This bill starts construction on the wall," he told reporters in a news conference on Capitol Hill.

"It funds our war on opioids. It invests in infrastructure. It funds school safety and mental health," he continued.

It provides $1.6bn in funding for Mr Trump's border wall, far short of the $25bn the White House had sought.

It also includes a provision that would legally allow the slaughter of wild horses roaming the American West as well as boosting military spending.

In a last-minute addition, it added funds to include the National Instant Criminal Background Check System (NICS) for gun sales.

It includes a 9% budget increase for the US National Park Service to address a repair backlog that advocates say are urgently needed.

"This is a necessary investment with broad returns, and we hope this trend continues," in future spending bills, said Kristen Brengel of the non-profit National Parks Conservation Association.

What about the Dreamers?
The Daca programme had protected roughly 700,000 immigrants known as "Dreamers". A deal on Daca was not included in the spending bill because Republicans and Democrats could not agree a trade-off.

The White House and Republicans offered Democrats a two-and-a-half or three-year Daca extension in return for including the $25b that Mr Trump wanted for the wall, reports say.

Democrats are reported to have said they would accept that, but only if a path to citizenship was created for all the 1.8m people eligible for Daca.

The White House rejected this and came back with another proposal but ultimately nothing was agreed.

"Democrats refused to take care of DACA. Would have been so easy, but they just didn't care," Mr Trump tweeted.

Are both sides happy?
House Democratic leader Nancy Pelosi called it "a tremendous victory for the American people".

"If you want to think you're getting a wall, just think it and sign the bill," she said, in a remark aimed at Mr Trump's Republican supporters in Congress.

But despite cross-party support, at least 90 conservative Republicans objected to the measure, calling it government spending run amok.

"This omnibus [spending bill] doesn't just forget the promises we made to voters, it flatly rejects them," Representative Mark Meadows, head of the hardline House Freedom Caucus, said after the vote.

"This is wrong. This is not the limited government conservatism our voters demand."