MGM, a classic Hollywood brand synonymous with “The Wizard of Oz” and Leo the roaring lion, was purchased for $8.45 billion on Wednesday by Amazon, a company currently valued at nearly $1.7 trillion. Being gobbled up by a tech behemoth is a fitting finale for a studio that has been whittled down over the last century by one technology disruption after another.

“MGM is really the story of Hollywood,” Jonathan Kuntz, a film professor at UCLA School of Theater, Film and TV, told CNN Business. “The studio has gone through all of the cycles of the film business over the last 100 years.”

“In many ways, MGM is the idea of the classic Hollywood studio,” he said. “And it tried to preserve that idea long after it was no longer a viable business strategy.”

Here’s a brief history of MGM, and why Amazon was likely so interested in buying it:

  • “More stars than in the heavens”

As Hollywood changes, much of it stays the same. Case in point: MGM started nearly a century ago with a merger.

James Bond, meet Jeff Bezos: Amazon spending $8.45B to acquire MGM

In 1924, Marcus Loew, a theater mogul, brought together Metro Pictures and Goldwyn Pictures, as well as Louis B. Mayer Productions, to form Metro-Goldwyn-Mayer.

Hollywood, as they say, would never be the same.

The studio exemplified Hollywood’s golden age. This period planted the seeds of what would become modern-day Hollywood and produced many films that would help define cinema: “The Wizard of Oz,” “Singin’ In The Rain” and “Ben Hur,” which won 11 Academy Awards. It was far and away one of the most successful studios of Hollywood’s early days.

“At one time, MGM was the most prestigious studio in Hollywood,” Leonard Maltin, a film critic and historian, told CNN Business. “It had a glory period that ran for decades.”

Since MGM was a big part of the studio system, which held actors under contract at different studios, it also helped to create some of Hollywood’s most glamorous stars, such as Greta Garbo, Clark Gable and Joan Crawford.

“It was said of MGM that they had more stars than in the heavens,” Maltin added.

But as Hollywood changed with the advent of TV, MGM was “one of the most reluctant to change,” Kuntz pointed out.

“MGM tried to preserve the old ways of Hollywood,” he said. “You might say it was in first place during the classic era of Hollywood and has been arguably in last place during the modern era of Hollywood.”

  • Kerkorian, Turner and UA

Much like the present moment, the late 1960s were a turbulent time for Hollywood. The rise of television and the changing tastes of audiences disrupted the business of Hollywood, undercutting the bottom line at the box office.

MGM, like other studios, was not immune to the changing times and struggled to adapt.

In 1969, Kirk Kerkorian, a business magnate, took control of MGM and used the brand’s prestige to build hotels like the MGM Grand hotel rather than focusing on the studio itself. The studio, in the meantime, faded from what it once was.

This was the “beginning of a 35-year period when Kerkorian would buy and sell MGM three times,” according to Tino Balio, professor emeritus of communication arts at UW-Madison, who also authored a book about MGM.

At the studio, Kerkorian put James Aubrey Jr. in charge of MGM, who used “draconian methods” to cut costs, Balio said.

Ultimately, MGM became a shell of its former self in the 1970s, but was somewhat bolstered by acquiring United Artists in 1981. UA was known for hit brands like James Bond. However, it wasn’t long before MGM was a part of yet another deal.

Ted Turner, the businessman who founded CNN, bought the newly formed MGM/UA Entertainment Co. in 1986. Turner wanted to use the the studio’s extensive library to show its films on his cable networks. Amazon bought MGM for its library, too, but instead of cable it’s for streaming via Amazon Prime Video.

The new merged studio produced some hits over the years, but was bought and sold repeatedly as the years went on. Turner eventually returned portions of MGM to Kerkorian but kept MGM’s film catalog prior to 1986. That included some of MGM’s most classic films like “The Wizard of Oz.”

“MGM was very much left behind in the 1990s when other studios were bulking up and becoming global companies,” Kuntz noted.

MGM eventually was repurchased by Kerkorian in 1996. It bought up film libraries from different studios like Orion Pictures, which led to “the world’s largest film vault,” according to Balio.

  • Amazon

Kerkorian sold MGM for the final time in 2005 to a group of investors led by Sony. Balio said Sony wanted “MGM’s library of 4,000 films to help its Blu-ray technology win the DVD high definition format war.”

The studio eventually filed for bankruptcy in 2010 and focused more on its home entertainment and its TV offerings than its film slate.

However, MGM’s movies still mattered because of James Bond — one of the most successful and popular franchises in movie history.

“James Bond is really the one film franchise left out there,” Kuntz said. “Everything else has been bought up.”

And that leads to Amazon.

Amazon is investing even more heavily in growing its position in the entertainment world and MGM helps facilitate that thanks to its library.

Beyond Bond, MGM also houses franchises including “The Handmaid’s Tale,” “RoboCop,” “Legally Blonde” and the Epix TV network, which MGM took sole ownership of in 2017.

Amazon’s purchase of MGM also marks the latest salvo in the streaming wars, amid other deals — from Disney’s acquisition of Fox’s entertainment assets to the pending deal to combine CNN parent WarnerMedia and Discovery — as companies bulk up.

Yet, for MGM, Amazon is just the latest example of the studio being tossed around in another Hollywood sea change.