Short answer: Become an A-list, bestselling author, with millions of copies of your book sold and then only option your film rights to a lesser-accomplished producer or director who looks up to you.
Long answer:
It’s a 99.9% chance you will get *no* say in casting (much less “major say”) unless you produce the film yourself.
What producer and director is going to agree to this given that your casting choices could be objectively horrible? There’s also the practicality of your choices — you might want someone you like or think is ideal, but who is unavailable, too expensive, or difficult to work with. There’s more to the choice than merely the right artistic fit.
Making a successful film is difficult enough without the meddling of an author. Not only is it extraordinarily rare for an author to have say in casting, it’s rare to have much say in the script and other aspects of the film. You need to rise to be a mega-selling, A-list author before you even have a chance at such input.