Board members of CBS and Viacom worked most of the weekend in an effort to reach a long-awaited merger agreement for the two halves of the Redstone media empire.

Sources close to the situation said the sides have made progress since Friday in hashing out some of the final details in the tie-up between the media conglomerates that are both controlled by the Redstone family’s National Amusements holding company. An agreement in principle could be announced as early as Monday although sources cautioned that with negotiations extending late into Sunday evening an early morning announcement before the market opens on Monday might be ambitious. Nonetheless, multiple sources close to the situation expressed optimism that the deal would cross the finish line after the third try in as many years.

By multiple accounts, the biggest final hurdle is the stock exchange ratio that will set the final pricetag for the all-stock deal. A previous round of talks in early 2018 settled on an exchange ratio of .61 CBS shares for every share of Viacom stock. Viacom’s market cap as of Friday was $12.3 billion, with shares closing at $30.01, compared to CBS’ closing price of $48.91 with a market cap of $18.3 billion.

The sale discussions this time are believed to be hovering at a pricetag valuing Viacom in the neighborhood of $13 billion, with the CBS side asserting that the merger premium has been baked into Viacom’s stock price in recent months amid market speculation that the companies would eventually come together.

CBS and Viacom were merged by Sumner Redstone in 2000 but split apart again in 2006. Shari Redstone, National Amusements president and vice chair of the CBS and Viacom boards, has advocated for the reunion in order to bolster both companies.

The boards have also been hammering out the final details of a management team and new board that would blend Viacom and CBS representatives. Viacom CEO Bob Bakish will take the helm of the combined company. CBS’ acting CEO Joe Ianniello is understood to be in line for a top post running CBS-branded assets.

The CBS-Viacom courtship has had a tumultuous history, which erupted in litigation last year under the previous CBS leadership regime headed by Leslie Moonves, who opposed the re-merger. Moonves was ousted last September amid sexual misconduct allegations and CBS’ board of directors was also overhauled. CBS and Viacom’s current boards have every incentive to push hard on price as the deal is sure to be scrutinized for possible shareholder lawsuits.

Representatives for CBS, Viacom and National Amusements declined to comment.