Whilst setting up software package deals in the Linux operating program, some packages count on other offers to functionality correctly. At times they are previously mounted on the system, but, in other scenarios, they mounted with the package quickly. These dependent offers are termed offer dependencies.
There are many ways to get dependencies particulars, these kinds of as employing apt package deal supervisor, dpkg command, or putting in a instrument.
Let’s start with the APT offer management technique to get the dependencies of a package deal.
How to Test Package Dependency with APT Demonstrate:
Execute the “apt clearly show” command with the package identify to get the entire specifics of a package deal.
Syntax of working with this approach is:
Let us test what outcome you get for the “Mozilla firefox” package deal when functioning:
As proven in the earlier mentioned graphic, the “firefox” package deal relies upon on different libraries. The APT bundle supervisor plays a critical function in the Linux procedure as it installs most of the dependencies quickly.
How to Test Dependencies Info with APT-Cache:
If you require the constrained script of dependencies data, go with the “apt-cache” command.
Use the presented syntax:
apt-cache relies upon [package_name]
Let us consider an instance for much better comprehension. Check out the dependency info of the “mozilla firefox” package deal:
apt-cache depends mozilla firefox
Acquire a glimpse at yet another case in point!
To get the dependencies facts of PHP:
How to test dependencies of a “.deb” offer file:
If you have .deb file to set up the software package bundle, then the “apt” command will not operate.
For this, you can run the “dpkg” command with the “-I” or “–info” selection to get particulars. So, the syntax would be:
dpkg –details [deb_file_path]
Suppose I have the “.deb” package deal of Teamviewer in my Ubuntu device. To get its dependencies detail, execute the talked about command:
dpkg –info Downloads/teamviewer_15.16.8_amd64.deb
The above section was how to get package deal dependencies depth through apt and dpkg command.
But if you want a tool, then stick to the approach supplied under:
How to look at dependencies with the “apt-rdepends” instrument:
There are several resources to examine offer dependencies, and you could get perplexed about which resource is the correct tool to install. Also, you are unable to be taking a threat to put in any dependency that has an effect on the functioning program.
The apt-rdepends is an authentic software that will help to listing down all the dependencies a program bundle has. It is not a constructed-in device to get it, use the command stated beneath:
$ sudo apt set up apt-rdepends
The syntax of the apt-rdepends is straight forward:
apt-rdepends [options] [package_name]
Suppose you want to figure out the PHP dependencies. For that, execute the supplied command to get the desired output:
Similarly, if we just take yet another example:
To reverse this, see what other offers count on a certain software program package, use the “-r” selection.
For instance, to check deals checklist depend on the vlc offer, the command is:
The write-up has proven us how to look at the offer dependencies of a package on Ubuntu 20.04.
We have located various techniques to get deal dependencies applying the command line. The APT package deal administration method performs an essential job as it installs most of the dependencies routinely. But if any software program has downloaded through the .deb offer, then the “dpkg” command is instructed.
The “apt-rdepends” tool is an alternate system to check out dependencies. Using this software, you can get the record of specific package deal dependencies and come across the reverse of it.