Veteran quarterback Chase Daniel has agreed to a two-year deal with the Chicago Bears, the team announced Wednesday evening.

Daniel will serve as the primary backup to Mitchell Trubisky, the second overall pick in last year's NFL draft.

Daniel tweeted earlier Wednesday:

Bears head coach Matt Nagy was the quarterbacks coach for the Kansas City Chiefs during Daniel's three seasons with the team (2013-15).

The Bears released quarterback Mike Glennon on Wednesday.

Daniel, 31, has spent nine years as a backup with the New Orleans Saints, Chiefs and Philadelphia Eagles -- making two career starts in Kansas City. But the former undrafted rookie from Missouri is still hoping to prove he can be a late bloomer, in the vein of Nick Foles and Case Keenum.

Daniel (6 feet, 225 pounds) originally joined the Saints in Week 1 of the 2009 season after being released by the Washington Redskins. He spent four years backing up Drew Brees before signing more lucrative deals with the Chiefs and Eagles.

He thought he might get a chance to start in Philadelphia when he signed a three-year, $21 million deal in 2016, but the Eagles traded up in the draft to select Carson Wentz. Daniel returned to the Saints a year later after asking for his release.

ESPN's Mike Triplett contributed to this report.