My own personal thoughts are that with hardware of that age, it's probably burning electricity at a rate that means that within a year or so, you could pay for an entirely new replacement low energy machine that will most likely be more compute powerful than whatever old clunker you're running now. Not to mention that old machines have parts that fail more often..
Your alternative is to set up your own build environment and start learning how to patch things. And that will be difficult - to use the sudo example, the patch for CentOS 7 does not apply to the sudo code from CentOS 6. It tries to patch several non-existent files and fails. So you're going to need at least a passing familiarity with C coding and then you're going to need to work out how to back port those el7 patches to el6 and, by the sounds of it, el5 which is hideously out of date and insecure.
Failing all that, you'll have to find a distro that runs antiquated packages and libraries on which you can run your old out of date applications.
Did you even try running them on a modern distro?
OK. That is not possible.Sometimes we just need an answer to our question, even if that answer is "I don't know" or "that is not possible".