The District will receive $6 million in a settlement of its case against the general contractor that headed the renovation of the library, severely damaged in 2007 by a three-alarm blaze. (Michel du Cille/The Washington Post)

Attorney General Irvin B. Nathan announced the agreement in a news release Friday. The city will receive the settlement from the insurance carriers for Dynamic Corp., a firm with offices in Hyattsville and the District, and subcontractor Two Brothers Contracting, which also has local offices.

The city had initially sued Dynamic for $13 million in damages to the 76-year-old building on R Street NW. The library reopened last year in a $23 million restoration.

According to the news release, the attorney general’s office was prepared to go to trial “but agreed to the settlement to avoid the costs and uncertainty of pursuing civil litigation further, and to allow the parties to put this incident from nearly five years ago behind them.”

Nathan said in a statement that the settlement is “a substantial restitution for District of Columbia citizens after this unfortunate destruction of valuable historic public property.”

Dynamic could not be reached for a comment. A voice mailbox at the company’s Hyattsville office was full.

The blaze drew publicity because of the historic building, a 1935 Georgian revival mansion. The fire took place on the same day as a fire that destroyed the historic Eastern Market, which reopened in 2009 after a $22 million renovation. That fire was blamed on a electrical issue.