It's Just Your Time...
They don't really have a choice but to pass on eventually. As the rules say...
You cannot resurrect someone who has died of old age.
So, yes: they have no reason to not live a very long, long life for whatever race they are and ripen to the oldest age possible. A human emperor could rule for over 100 years, defying every would-be assassin with life-giving magic. But no amount of resurrection can make you immortal.
So the answer to your question is: they probably wouldn't choose to pass on. But there is no choice. That's part of the curse (blessing?) of being mortal.
Note that keeping a mortal alive past their due date is outside of the scope of even a wish spell. As it says...
You may try to use a wish to produce greater effects than these, but doing so is dangerous. (The wish may pervert your intent into a literal but undesirable fulfillment or only a partial fulfillment.)
...But You Can Become Something Else
The one option open to them would be to embrace some form of undeath, such as lichdom. However, it's noted in the process of becoming a lich that the entity must themselves be a very powerful spellcaster to be able to create their phylactery, the requirements of which are as follows:
Each lich must make its own phylactery, which requires the Craft Wondrous Item feat. The character must be able to cast spells and have a caster level of 11th or higher. The phylactery costs 120,000 gp and 4,800 XP to create and has a caster level equal to that of its creator at the time of creation.
Note that becoming a lich is considered "unspeakably evil" (unless you're using some non-core source books like Monsters of Faerun, which contains "good liches"), so this would also be a substantial deterrent, regardless of the power level required to become one. This also ignores the basic philosophical argument of "is a lich the same person/creature as the one it was in life?" which is a bit outside the scope of this question, but something relevant to think about. It would affect other changed statuses as well, like if the ruler wanted to become an abomination such as a Worm That Walks or had someone try to rip them out of their afterlife plane as whatever kind of Outsider they may have become.
Reincarnate Cheese
Finally, as @SouthpawHare pointed out in the comments below, the spell reincarnate actually will allow the being to come back to life in the form of a random young-adult humanoid. The spell even notes that...
A wish or a miracle spell can restore a reincarnated character to his or her original form.
The spell still can't revive you if you've died of old age. But you could theoretically bypass this by simply hiring someone to murder you, committing honorable seppuku, or otherwise having a violent, non-age-related death.
So for a ruler who has basically limitless gold resources, it shouldn't be a problem to continually arrange for their own unnatural death, and then have a reincarnate and wish spell cast upon them to return them to their normal 20-something-year-old form. This could potentially allow the ruler to live forever, as long as he gains enough experience in his next lifetime to gain at least one level. If he keeps staying at 1st level, he will eventually run out of Constitution, per the following functionality:
The subject’s level (or Hit Dice) is reduced by 1. If the subject was 1st level, its new Constitution score is reduced by 2. (If this reduction would put its Con at 0 or lower, it can’t be reincarnated). This level/HD loss or Constitution loss cannot be repaired by any means.
They also can't be killed by a death effect or turned into Undead in the interim, or the reincarnate would have no effect. Of course at that point, you could in theory be resurrected normally since you didn't die of old age.
With that said, while this follows the RAW (rules-as-written), it's my opinion that it violates the RAI (rules-as-intended). If I was the GM of this game, I wouldn't allow such a loophole. And honestly, it would likely infuriate the in-game gods as well (at least, the Druidic ones). Limitations are placed on mortal magic for a reason. (If you're playing in the Forgotten Realms setting, for instance, the gods still remember very clearly that whole fiasco with the Netheril Empire and the hubris of humans who thought they could be gods.)
Even if the GM isn't willing to modify the RAW, there is this nice little tidbit in the reincarnate text to have fun with:
A reincarnated creature recalls the majority of its former life and form.
(emphasis added)
One good cheese deserves another. Isn't that how the saying goes?
Post Script
I'm sure that scattered throughout the dozens and dozens of source books for 3.5 there are ways to break this and find some loophole to allow a mortal to live forever. As @BrianBallsun-Stanton asked, "[What] about polymorphing into an elan?" It's a good question, and I honestly had never even heard of an elan before he mentioned it in this thread.
A comprehensive analysis of every single possible trick a mortal being could use to try to live forever would create an entire reference book, and I'm unwilling to create one here. The notes above are intended as the "happy path" through the rules and rely mostly on the core rule books. There will always be some fringe cases in a system with as many out-of-control source books as 3.5 has.
Bottom line: the spirit of the rules is that a mortal being cannot live forever through mortal magic. It is impossible. And the game should be played as such. Anything else is the worst kind of munchkinism.
Best Answer
The exact cost is up to your DM. He is the only one who knows the availability of any resources needed to build a new village. He may even decide that money is not the only thing needed. Workers may disagree to come to the place because they are afraid of a dire bear in the nearby forest; the place may be surrounded by a hard terrain and the materials couldn't be transported there. And so on. The DM can have any in-game or plot considerations. You have to discuss it with him before taking any in-game actions.
To give you a hint about the possible price I'll present you some calculations and considerations.
First of all, you probably don't need to build a house for every person. People in villages usually live in families. So you need one house per family. I know nothing about the number of families there are. Lets assume there are 3 -10 people per family. Then you need 5 – 17 houses. DMG lists a price of 1000 gp for a simple house.
link
It results in 5000 – 17000 gp.
But medieval villagers often were not hiring architects or labourers to build houses. An average community had every skilled craftsman needed to build a simple house. If that is the case you only need to pay for the raw materials, i.e. 1/3 of the final price (see Craft skill).
If this is true for your rescued vilagers, you need 1666 – 5666 gp.
Note that these prices are average prices recommended by DMG. Your DM can modify them or use entirely different values.