简体   繁体   中英

how can I get a complete pkg list for an installed app (debian)?

After installing an application in one linux distro, I'd like to be able to install the same in another but in synaptic it isn't always clear which top level pkg to select to get the entire application. ubuntu though has a software center that puts the top level pkg only to select and then via some magic knows all the dependencies to include for a successful install.

Is there some way to get a complete list (via an apt-get or dpkg command piped into a file ) of all the packages that came with say, monodevelop and then use that file as a reference on another distro (also debian based)?

My previous post @ stack_overflow answered how to migrate an entire installation set from one system to another so now I know how to provide file input for an install.

Strictly speaking it's not possible to do so. Packages declare dependencies on other packages, a hierarchy of packages that need to be installed can only be compiled at the moment of installation.

Example case:

Application package A depends on packages B and C. Package C depends on package D.

Machine X already has package C (and therefore package D, because it's a dependency of package C). You want to install the application using package A. The package manager now checks if all the dependencies are met. In this case, C is already installed, so there are just the packages A and B that need to be installed.

Machine Y doesn't have any dependent packages installed. You want to install the application using package A. The calculated list of unmet dependencies would be A, B because A needs it, C because A needs it, and finally D, because C needs it.

I hope it's getting clear: You needn't manually specify all packages for an application, the package manager does that for you.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM