Major League Soccer is lining up mighty Real Madrid as its opponent for this summer's All-Star Game in Chicago, multiple sources have told ESPN FC.

The deal was not yet final as of last weekend, but an agreement is expected that would have the defending UEFA Champions League winner play a team of top MLS players on Aug. 2 at Soldier Field, the sources said.

Real Madrid would become the first Spanish club to participate in the event.

World Soccer Talk reported in October that Barcelona -- Real's chief La Liga rival -- had been invited to play the MLS All-Stars. But negotiations between MLS and Barca broke down after the club went back to the league with additional requests, one source said, without specifying what those asks were.

Before this summer's All-Star Game, Real Madrid star Cristiano Ronaldo will have participated in the FIFA Confederations Cup with Portugal. He would have 31 days between the final on July 2 and the game in Chicago.

In 2014, Bayern Munich had players like Philipp Lahm and Manuel Neuer, who had won the World Cup with Germany 24 days earlier, fly to Portland hours before the All-Star Game because they were contractually obligated to take part.

Cristiano Ronaldo and Real Madrid could be heading to Chicago to face the MLS All-Stars this summer. Getty Images

The 2017 MLS All-Star Game will be the 13th consecutive midsummer classic in which the league's best players meet an international foe. That streak would have dated to 2002 had Real not backed out of playing in the 2004 All-Star Game, for which MLS ended up reverting to its original East-West format.

The following summer, an MLS "select" team lost 5-0 to Real in Madrid at the Santiago Bernabeu.

Madrid have played in the U.S. in seven of the past eight summers, but have not been to Chicago since facing Chivas Guadalajara in July 2005. In 2014 and 2016, over 105,000 people watched Real play at Michigan Stadium.

Last July, Arsenal beat the MLS All-Stars 2-1 in San Jose, California. MLS has also hosted Bayern Munich, Chelsea, Manchester United, Roma and Tottenham in recent years. The league has gone 9-4 since the format switch became permanent. Chelsea were Champions League holders when MLS beat them in 2012.

Real Madrid won its record 11th European title last June. The 32-time Spanish champion currently sits one point above Barcelona at the top of the table in La Liga.