FX’s “Y: The Last Man” pilot has set its main cast.

Diane Lane has signed on to star in the drama series pilot, which is simply titled “Y,” along with Barry Keoghan, Imogen Poots, Lashana Lynch, Juliana Canfield and Marin Ireland.

Based on DC Comics’ acclaimed series by Brian K. Vaughan and Pia Guerra, the project traverses a post-apocalyptic world in which a cataclysmic event has decimated every male mammal save for one lone human. The new world order of women will explore gender, race, class and survival.

Keoghan will play Yorick Brown, the main character from the graphic novels on which the show is based. He is described as a young man quick to use humor to deflect from his problems who may be the lone male survivor of a worldwide plague.

Keoghan is known for his roles in films like Yorgos Lanthimos’ “The Killing of a Sacred Deer” and Christopher Nolan’s “Dunkirk.” Both roles earned him a spot on Variety’s “10 Actors to Watch” for 2017. He is repped by WME, Management 360, and Troika.

Poots will play Hero Brown, Yorick’s sister. She is a tough and confident EMT who nurses a deep emotional trauma that often leads her to cross personal and professional lines.

Poots broke out in the film “28 Weeks Later,” and has gone on to star in films like “Green Room,” “Knight of Cups,” and “I Kill Giants.” Her television credits include Showtime’s “Roadies,” BBC’s “Miss Austen Regrets,” and BBC’s “Christopher and His Kind.” She is repped by CAA and Troika.

Lane will star as Senator Jennifer Brown, Yorick and Hero’s mother. A Junior Senator in her first term, Senator Brown has already made a name for herself in political circles for her willingness to put personal ideals above politics.

Lane is an Academy Award known for her roles in films like “Unfaithful,” “Under the Tuscan Sun,” “Chaplin,” “Hollywoodland,” “Nights in Rodanthe,” “Trumbo” and more. Lane’s current projects include a co-starring role in the sixth and final season of “House of Cards” and Matthew Weiner’s “The Romanoffs” for Amazon. She is repped by UTA.

Lynch will play Agent 355, a Secret Service agent who performs the duties of her job with the utmost professionalism, even under the most unexpected set of circumstances. Lynch recently secured a role in the upcoming Marvel film “Captain Marvel.” Previously, she was seen in the lead role of Shonda Rhimes’ ABC show “Still Star-Crossed” and also appears as a lead in the miniseries “Bulletproof” airing later this year. She is repped by ICM, Alan Siegel Entertainment, and BWH Agency.

Canfield will play Beth. A Brooklyn-based knife maker, Beth grew up on a farm and went to New York to experience the big city. She finds something endearing about the hapless Yorick and when they’re together, there’s the undeniable spark of two kids in love. Canfield currently appears in a recurring role on the HBO series “Succession.” She holds an MFA from the Yale School of Drama. She is repped by ICM and Brookside Management.

Finally, Ireland will play Nora, the President’s senior assistant and right hand. She effortlessly balances family life with a job navigating the corridors of power. Ireland has appeared in shows like “Sneaky Pete,” “Girls,” “Homeland,” “Masters of Sex,” and “The Slap.” Most recently she was seen in the Lifetime movie “Flint,” about the Flint water crisis, playing activist Melissa Mays. She is repped by ICM and Untitled Entertainment.

Michael Green and Aida Mashaka Croal are set to serve as co-showrunners on the project, and will executive produce alongside Nina Jacobson and Brad Simpson of Color Force. Vaughan will also executive produce. Melina Matsoukas will direct the pilot and also serve as an executive producer.

An adaptation of “Y: The Last Man” has long been in the works. It was originally set up as a film before FX acquired the rights to develop it as a series. The cabler ordered the project to pilot back in April.