The agreement will avert a battle over control of the company that was expected at an Aug. 1 shareholders vote.
Under the agreement, eight members of the current board will seek re-election. Icahn will be appointed to the board, and two other seats will be filled based on a list of nine candidates recommended by Icahn.
Yahoo also said Robert Kotick will not stand for re-election to the board. After he steps down and the Icahn slate is added, Yahoo's board will end up with 11 members.
Icahn had wanted to replace Yahoo's directors with his own hand-picked slate to negotiate a sale of all or part of Yahoo. In a statement, Icahn said he believes the sale of the company still merits "full consideration."
Microsoft had attempted to buy Yahoo earlier this year, and Icahn made clear he would try to negotiate a sale to the software company if he took control of Yahoo's board.