Terry Gilliam's "The Man Who Killed Don Quixote" continues to be a cursed project.

On the eve of the movie's debut at the Cannes Film Festival, Gilliam has suffered a minor stroke, though he is recovering well in London now. But the director also lost the movie's distribution deal at Amazon Studios, according to IndieWire.

Gilliam began working on "The Man Who Killed Don Quixote," a loose interpretation of Miguel Cervantes' classic novel way back in the late 1990s. It took him about two decades, a revolving door of financiers, numerous cast changes (Johnny Depp was once attached), and a couple of natural disasters —and one documentary, 2002's "Lost in La Mancha," that chronicled all the troubles.

But things seemed to turn around. Jonathan Pryce and Adam Driver joined the cast and production was finished. A trailer was even released.

The director made the distribution deal with Amazon in 2015. At the time, he said, "Amazon and the like are interesting because they are all still in their formative stages. They're not a bureaucracy that has been around for years like the studio system, and so they're full of people that are open to new and fresh ideas. So it's a good time to be working with people like that."

It's not clear why Amazon decided to drop the movie and a source declined to comment to IndieWire. But Gilliam has been involved in a legal battle with a producer over the rights to film. The verdict in Gilliam's favor means the movie can go ahead with its Cannes showing on May 19.