I was wondering if it was possible to check what package another package is a dependency of.
For example, jetty is mysteriously installed and running on my system and I'd like to check whether it is a dependency of something else.
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.
Sign up to join this communityI was wondering if it was possible to check what package another package is a dependency of.
For example, jetty is mysteriously installed and running on my system and I'd like to check whether it is a dependency of something else.
You can use apt-cache rdepends --installed jetty
to see what depends on jetty. This will show both depends & recommends, so you may want to check through the list of packages to see what the relationship is with jetty.
apt-cache rdepends jetty
will show you packages that break (and, i suppose, conflict with) jetty
.
sudo apt rdepends jetty
(Notice it is not using apt-cache but simply apt)
Nov 16, 2017 at 5:23
Go install apt-rdepends
. It doesn't only show immediate dependencies, but all the recursive ones, so will tend to give you a large output. So, use a pager as well.
$ apt-rdepends jetty | pager
. Note that this will list exactly the same depends multiple times. Output of apt-rdepends
1.3.0 isn't trivial for scripting as package name doesn't appear along each line...$ apt-rdepends --reverse jetty | pager
. Note that this will return all packages, not just installed...If you open Synaptic and find the package, you can right click on it and select Properties. Under the tab Dependencies you can see the packages that jetty depend on, and which packages is dependent on jetty (the dropdown list).