I'm a raging secularist. I don't believe I have an immortal soul, or that there are postmortem rewards and punishments for my acts upon this Earth. In the end, I answer only to my own conscience, to the society around me, and to whoever picks out my epitaph. Whatever of me survives my lifetime will carry forward through the_child, through my friends and through my fiction.
(This is not me being morbid or hinting at bad medical news, this is just me thinking.)
There's an immortality lottery in publishing. Homer won big. So did Sophocles, Paul of Tarsus, Dante, Shakespeare, Twain -- you name it. I have a lot of trouble imagining anything in our field being read millennia from now (actually, I have no trouble at all imagining it, I just have trouble believing it). Nonetheless, if I am able to write something that reaches beyond my immediate circle of friends, fans and casual readers, then I've touched other lives in a way that is meaningful to me.
This comes in part from having a books-are-my-best-friends childhood. I was much closer to Andre Norton and Robert Heinlein than I was to anyone who lived on my street or shared a classroom with me. Because we relocated every year or two, all my childhood friendships were of neccessity transitory. The books always came with us. It also comes from that sense of survivorship. I may not make it into the 22nd century, but there's a chance some of my words will.
Posterity is a motivator, not a structural feature of my writing. I don't sit around and think about it when I'm working on a story, any more than I sit around and think about verb tenses or market dynamics. It's just one of the things that keeps me coming back to the keyboard. One of the many things. And truthfully, I feel a bit foolish admitting it here. But this is important to me. Vanity, ambition, or personal quirk, I don't know which.
Whatever gets you to the words, right?