David Jackson | USA TODAY

AP

Evan Vucci, AP

WASHINGTON — President Trump linked his threats to kill the Iran nuclear agreement with his hopes to strike a deal with North Korea deal on Monday, saying Kim Jong Un should know that the U.S. will walk away if it doesn't think its partners are committed to compliance.

"I think it sends the right message," Trump told reporters at the White House.

Again attacking the "horrible" deal with the Obama administration struck with Iran, Trump said that "in seven years that deal will have expired, and Iran is free to go ahead and create nuclear weapons. That's not acceptable."

Trump, who faces a May 12 deadline on whether or not to certify the Iran deal, said he is still open to negotiating a new agreement. He also cited claims by the Israeli government that Iran is cheating on the agreement by pursuing nuclear weapons in spite of their pledge not to do so.

"I'm not telling you what I'm doing, but a lot of people think they know," Trump said during a joint news conference with the president of Nigeria. "And, on or before the 12th, we'll make a decision."

Trump spoke about Iran and North Korea on the same day he said he may be willing to meet with Kim at the demilitarized zone on the North-South Korea border, with a date to be determined.

In past weeks, Trump and aides have said that both Iran and North Korea should know that they are willing to walk away from any high-level agreement if they do not believe the other side is acting in good faith.

Some analysts said killing the Iran deal may send a different message to North Korea: That the United State can't be trusted to keep its commitments, so don't worry about compliance.

Trita Parsi, a supporter of the Iran agreement and author of Losing an Enemy: Obama, Iran and the Triumph of Diplomacy, said North Korea probably doesn't trust the United States anyway, but thinks it can get favorable terms because Trump seems so eager to get any kind of agreement.

"I think the North Koreans think they will get a really sweet deal from Trump because he's more concerned with the optics than the substance," said Parsi, president of the National Iranian American Council.

While expressing optimism about a Kim meeting, Trump said he is willing to walk away from a North Korea summit and a possible agreement if he doesn't see steps toward eliminating its nuclear weapons.

"I think it would be a great celebration if it works out well," Trump said. "And if it doesn't work out well, that's the way it goes."

In again denouncing the Iran deal, Trump praised new claims by Israeli Prime Minister Benjamin Netanyahu. Citing Iranian documents he said were obtained by Israeli intelligence, Netanyahu — a long-time vocal critic of the deal — said the Iranians have been lying in denying they want nuclear weapons.

"That doesn't mean I wouldn't negotiate a new agreement," Trump said, but added that "what we've learned has really shown that I've been 100% right."