EXCLUSIVE: Scott Free and Black Bear have set Jason Segel, Dakota Johnson and Oscar-winner Casey Affleck to star in The Friend, a fact-based touching drama that STX International will launch for offshore sales at the European Film Market. Directing is Gabriela Cowperthwaite, whose Blackfish was a BAFTA nominee for Best Documentary and who most recently helmed the Kate Mara starrer Megan Leavey.

Script is based on the Matthew Teague National Magazine Award winning article for Esquire Magazine, which was adapted by Brad Ingelsby. The Out of the Furnace scribe has written Mare Of Easttown, the limited HBO series that Kate Winslet is starring in with Gavin O’Connor directing.

The Friend tells the extraordinary true story of Nicole (Johnson) and Matthew Teague (Affleck) who, after learning that Nicole has just six months to live, receive the unexpected support of the couple’s best friend (Segel). He moves into their family home and puts his own life on hold. His impact on everyone is much greater and more profound than anyone could have imagined.

Related Story 'Raised By Wolves' Renewed At HBO Max For Season 2

Scott Free and Black Bear Pictures are producing, and Black Bear will fully finance. STXinternational and Black Bear Pictures teamed previously on The Marsh King’s Daughter, and the STX Entertainment subsidiary collaborated with Scott Free on All the Money in the World.

Pic is produced by Scott Free’s Kevin Walsh, Michael Pruss & Ryan Stowell, alongside Black Bear’s Teddy Schwarzman. Ridley Scott will be executive producer along with Black Bear’s Ben Stillman and Michael Heimler. Ingelsby, Teague and Ted Deiker will also be exec producers.

The film will start shooting on location in Fairhope, AL next month, in the town where the Teague family resides.

Teague said he was “thrilled and honored to see the story come to life this way, thanks to the filmmaking vision of Gabriela Cowperthwaite and a script that Brad Ingelsby and I worked on closely together. It captures what’s at the heart of the story: deep love and loss, and the saving grace of friendship. To have the talents of Dakota Johnson, Jason Segel and Casey Affleck help the story live on is remarkable. And I’m grateful to Scott Free and Black Bear, who have been both passionate and sensitive from day one. I hope the story gives people an honest glimpse of what it means to face mortality, and the value of having a true friend at your side, when that moment comes.’

·Said STXI’s John Friedberg, who’ll sell it at Berlin: “Occasionally you find yourself presented with the most incredible material that you know takes you into a whole different level of quality and potential. The Friend is that story for me and I am confident our partners will be blown away. Gabriela and the film team have assembled an incredible cast and crew and we can’t wait to see them bring this story to life.”

· Cowperthwaite is repped by WME, Black Box Management and Myman Greenspan; Ingelsby is repped by CAA, Energy Entertainment and McKuin, Frankel; Segel is repped by WME and Sloane, Offer; Johnson is WME, Lighthouse Management + Media, and Ziffren Brittenham; and Affleck is WME and Ziffren Brittenham. Teague is Paradigm.

Endeavor Content arranged the financing and will broker the U.S. distribution deal.