Recursive list of required packages for kickstart

JD jd1008 at gmail.com
Wed Jun 16 20:10:25 UTC 2010



On 06/16/2010 11:30 AM, James Antill wrote:
> On Wed, 2010-06-16 at 14:09 -0400, rarob at travelinglightfarm.net wrote:
>    
>> Hello all,
>>    I'm trying to generate a minimal list of required packages in order to
>> install a particular software package (which itself consists of several
>> packages).  Does anyone have a script (shell or python preferred) that
>> when given one or more package names, generates a list of the other
>> packages that would be required to install it?
>>    I know I can do 'rpm -Uvh --test<package names...>' to generate a list
>> of packages that are missing and would need to be installed before I can
>> install '<package names...>, but I'm looking for something that would
>> tell me the exhaustive list of all required package names.  So far my
>> google-fu has been lacking....
>>      
>   The usual way I do this on F-13 is:
>
> yum install mypkg --instalroot=/tmp/test-install-mypkg --release=13
>
> ...that'll give you the list of packages and the size (according to the
> rpms) they'll take when installed. You can even run the command to get
> the exact installed size.
>    

Nice idea - except rarob is not looking for the size but
the minimal list of required deps.

Why not pass the output through a script that will keep only
the names of the required packages (including their versions),
then pipe it through sort and pipe that through uniq
and you're done.
Finally, in the output of uniq,
If you see same package name listed more than once,
then the required version numbers are not the same -
which means you have 2 or more packages that require
package X of different release versions.


More information about the Rpm-list mailing list