Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

For example, there are packages and their dependencies:

a -> b (a require b)
b -> c & d
x -> a
y -> x
z -> x
z -> x & y

Now, give c and z, there are two dependency paths:

z -> x -> a -> b -> c
z -> y -> x -> a -> b -> c

The question is how to find out the dependency paths between two specific Debian packages?

P.S. The idea behind is to draw the dependency graph for a given set of packages, include the intermediate ones missing in the chain.

share|improve this question
add comment

1 Answer

Your overall problem might already be solved by using apt-cache dotty.

If you want to implement it yourself, use some graph algorithm to find a path. Or check the source code of apt-cache. ;-)

share|improve this answer
    
Thank you, I should describe it more clearly, apt-cache dotty creates the graph for a given set of packages, no more no less. And what's my object is to add the implicit dependents in the graph. –  Xiè Jìléi Dec 25 '10 at 12:40
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.