You are not logged in.

#1 2010-12-05 18:41:01

Ryujin
Forum Fellow
From: Centerville, Utah
Registered: 2005-05-12
Posts: 246
Website

[SOLVED]pacman query question

I need to generate a list of package dependencies for a list of packages for a project I am working on, so basically I need to be able to get all the deps for packages, eg:
pacman -Q? bash
glibc
readline >=6.1

So far all I have found returns results based on what deps are needed, not listing all deps, anyone know how to do this? Or do I need to crack open the package database?

Last edited by Ryujin (2010-12-06 04:09:25)

Offline

#2 2010-12-05 19:05:07

falconindy
Developer
From: New York, USA
Registered: 2009-10-22
Posts: 4,111
Website

Re: [SOLVED]pacman query question

The "problem" is that readline and glibc really are the only dependencies. Everything else is fulfilled by way of recursive dependencies (e.g. ncurses is a requirement but fulfilled because of readline). To that extent:

If you want a list of recursive dependencies for a package, you want pactree (which is currently part of pacman-contrib)
If you just want an easily parseable list of depends for a set of packages, you want expac (shameless self promotion)

Offline

#3 2010-12-06 04:09:09

Ryujin
Forum Fellow
From: Centerville, Utah
Registered: 2005-05-12
Posts: 246
Website

Re: [SOLVED]pacman query question

pactree -l <package> | sort -u | grep ^[[:alnum:]]

Thanks!

Offline

#4 2010-12-06 04:16:00

falconindy
Developer
From: New York, USA
Registered: 2009-10-22
Posts: 4,111
Website

Re: [SOLVED]pacman query question

`pactree -u <package>' would have worked!

Last edited by falconindy (2010-12-06 04:16:26)

Offline

#5 2010-12-06 04:24:52

Ryujin
Forum Fellow
From: Centerville, Utah
Registered: 2005-05-12
Posts: 246
Website

Re: [SOLVED]pacman query question

Double Solved!
Thanks smile

Offline

Board footer

Powered by FluxBB