Dunleavy's deal includes a partial guarantee in the third year, sources said.
Dunleavy, 34, had been eager to remain with the Bulls, where he had played the past two seasons under ex-coach Tom Thibodeau.
Chicago is working to complete an agreement with another Bulls wing player, Jimmy Butler, who is negotiating a four- or five-year contract extension, league sources said.
Dunleavy has emerged as a key contributor to the Bulls, averaging 9.4 points and 3.9 rebounds in 63 games last season.
The Bulls can't officially sign Dunleavy until July 9 when the NBA's free-agent moratorium ends.
More NBA coverage: