President Donald Trump is expected to sign a border security deal so as to avoid another U.S. government shutdown, local media reported Wednesday.

The legislation, which includes $1.375 billion for fencing and other physical barriers at the border with Mexico, is likely to be finalized later Wednesday, with votes expected Thursday in the House of Representatives and the Senate to follow.

[Getty/Kyodo]

If Trump does not sign a bill by midnight Friday, another partial government shutdown will ensue.

Speaking to reporters on Wednesday, Trump said the White House will take a serious look at the legislation. "We'll be looking for land mines because you could have that."

However, he said, "I don't want to see a shutdown. A shutdown would be a terrible thing."

Wall funding in the legislation, to which House and Senate negotiators agreed in principle Monday night, is a far cry from what Trump had been seeking.

It features $1.375 billion for 55 miles (88 kilometers) of new bollard fencing along the southern border, far short of the $5.7 billion Trump had demanded for more than 200 miles of steel and concrete wall.

In addition to signing the legislation, the president would likely pursue an executive order to reallocate additional federal funds to barrier projects, the Washington Post reported, quoting a White House official.

Trump's demand for $5.7 billion in funding for the wall led to a 35-day partial government shutdown through Jan. 25, the longest in U.S. history.