Sorry I missed your note as to which distribution you're using.
I don't think RHEL includes yum or has yum repositories.
You can check your server to see if you have yum:
# rpm -qa | grep yum
If so, then you should set it up
$ man yum
(Be sure to use my exclude list; you can find it by searching these forums for "yum exclude" (without the quotes.)
If you don't have yum you can install it from the CentOS 3 mirrors, but you'll then be updating and installing CentOS packages rather than Red Hat packages. Your system won't care, but Red Hat will if you need them for support.
Or you can check a Red Hat forum to find out if RHEL has something similar that will resolve dependencies automatically.
Or you can just keep manually installing (using rpm) until you don't get the errors.
Jeff