Take the 2-minute tour ×

I need to install a vendor package onto a non-default directory (say /opt). By default, package gets installed in /usr/local/bin directory.

If I use command rpm -ivh package.x86_64.rpm --root /opt I get error message /bin/sh is needed by package.x86_64. After doing Google, my understanding is that it happens because rpm is looking for dependencies in /opt directory. Is that true?

Given that I don't have vendor SPEC file, is it possible to fix this problem somehow?

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

I think you want the rpm option --prefix, not --root. --prefix will install into a different root directory for relocatable rpms, whereas --root uses the path at --root "for all operations" (from the man page) even dependency checks.

share|improve this answer
that works. thank you. –  user837208 Sep 6 '11 at 20:49
add comment

Your Answer


