apt-cache show <package> shows also it's dependencies.
yum info <package> does not show dependencies, but it obviously know them.
How to ask yum for dependencies of specified package?
yum doesn't have that capability. Use the
OR to also see which additional RPM packages are needed to satisfy the dependencies, use --resolve
from yum's manual:
Update for dnf
To do the same thing with dnf, we can do
If you have a local RPM, you can get a list of dependencies via: