Complex sentence: Kershner was eventually hired when Sinatra was attached to the title role, but when Sinatra eventually left the film, so did Kershner.
Split into simpler sentences: Kershner was eventually hired when Sinatra was attached to the title role. But when Sinatra eventually left the film, so did Kershner.