GREENSBORO, N.C. — North Carolina legislative leaders are giving formal notice that their lawyers will appeal a Greensboro federal judge’s ruling that legalized same-sex marriages in the state.

Attorneys hired by Senate Leader Phil Berger and House Speaker Thom Tillis say they’re appealing. Lawmakers decided to appeal earlier this year after state Attorney General Roy Cooper declared all potential legal defenses were exhausted.

The appeal’s arguments will be explained later.

The notice of appeal was filed Thursday, the same day a federal appeals court in Cincinnati upheld gay marriage bans in four Midwest states. A federal judge on Friday ruled that Missouri’s same-sex marriage ban is unconstitutional.

The appeal goes to the 4th U.S. Circuit Court of Appeals in Richmond, Va., which ruled this summer that Virginia’s same-sex marriage ban was unconstitutional. That ruling led the way for North Carolina’s ban to be struck down after the U.S. Supreme Court declined to hear an appeal.

A federal judge in Asheville also ruled the North Carolina gay marriage ban was unconstitutional and rejected a bid by Tillis and Berger to appeal.

Associated Press contributed to this report.