, whose deaths saddened the entertainment world this weekend, had worked together on an upcoming film this past spring.
, starring Mac and
Samuel L. Jackson
, is named for the famous hit "Soul Man" that Hayes wrote with David Porter.
Mac and Jackson actually do their own musical and dance performances in the film about two aging backup singers who haven't seen each other in 20 years but reluctantly agree to travel together for a tribute performance in honor of their recently deceased band leader.
The movie shot scenes in Memphis, Tenn., in April, including one in which Hayes is in the audience as Mac and Jackson perform the legendary songwriter's "Do Your Thing."
Mac, 50, died from complications due to pneumonia in a Chicago-area hospital early Saturday. Hayes, 65, was found near a treadmill in his Tennessee home barely a day later and pronounced dead at a Memphis hospital. His cause of death was not determined but no foul play was suspected.
Due out in November, the film is directed by Malcolm D. Lee and also stars Sean Hayes, Jennifer Coolidge and John Legend.
Robert Ramsey and Matthew Stone co-wrote the screenplay. -