The waiting game is finally over, as unrestricted free agent J.R. Smith is back with the reigning NBA champions.

The Cleveland Cavaliers announced Saturday they've re-signed the 31-year-old scoring guard. ESPN's Marc Stein first reported the transaction, noting the deal spans four years and is worth $57 million.

It was a long and arduous process to bring Smith back to the Cavaliers, just like it was in 2015 when management waited until Sept. 2 to re-sign him to a one-year contract after he opted out.

Cleveland was reportedly willing to pay the 12-year pro in the range of $10 million to $11 million, but wasn't willing to go above and beyond that number, even though Smith desired something closer to $15 million per season. That became a major issue with the organization already so deep into the luxury tax.

This new deal will be worth more than $14 million annually, but not all of it will be guaranteed, according to Cleveland.com's Joe Vardon. The first three seasons will be fully guaranteed for $45 million over the first three seasons regardless of what happens in the fourth year, says Stein.

There were several other teams that could have given Smith what he wanted financially had the Cavaliers prolonged negotiations, as well. The Boston Celtics reportedly had interest, but they would have needed to clear cap space to make a signing happen.

Four-time league MVP LeBron James was constantly in Smith's corner, calling him "probably the most liked guy on the team" last month. The King also credited Smith's role during the playoffs in helping the Cavaliers capture the NBA championship by overcoming a 3-1 series deficit against the Golden State Warriors.

He was lights out shooting the rock during 21 appearances in the playoffs, connecting on a scorching 43.6 percent of his attempts for 11.5 points in 34.8 minutes as a starter. Being a 3-point marksman is what he's become notorious for over the years, as only Kyle Korver and Ray Allen have more makes from the perimeter than Smith (1,679) since he went 18th overall to the New Orleans Hornets in the 2004 draft.