A tool to list package deps sorted by buildtime?

2011-01-26 Thread Michael Schwendt
Scenario:

Assume I have package foo. It's installed already, and the local RPM
database covers it and all its dependencies.

App foo used to run fine a month ago, but a rebuild no longer does.
Dependencies have been updated. Too many for rpm -qa --last|less or
yum's log to be helpful.

I'd like to run an RPM query on foo that displays the %{buildtime}
for all of foo's Requires, sorted by buildtime.

Does anyone know of an existing tool that can do exactly this already?
Or a script that achieves the same on top of an ordinary rpm --qf ... query?
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel


Re: A tool to list package deps sorted by buildtime?

2011-01-26 Thread Richard W.M. Jones
On Wed, Jan 26, 2011 at 12:52:52PM +0100, Michael Schwendt wrote:
 I'd like to run an RPM query on foo that displays the %{buildtime}
 for all of foo's Requires, sorted by buildtime.
 
 Does anyone know of an existing tool that can do exactly this already?

No, but I have a script which can list all the dependencies of a
package recursively [using data from yum, not rpm] if that is helpful:

http://git.annexia.org/?p=febootstrap.git;a=blob;f=febootstrap_yum_rpm.ml;h=e70940df06edb87b616d739bf0912d742809842c;hb=HEAD#l38

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
virt-top is 'top' for virtual machines.  Tiny program with many
powerful monitoring features, net stats, disk stats, logging, etc.
http://et.redhat.com/~rjones/virt-top
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel


Re: A tool to list package deps sorted by buildtime?

2011-01-26 Thread Michael Schwendt
On Wed, 26 Jan 2011 11:56:43 +, Richard wrote:

 No, but I have a script which can list all the dependencies of a
 package recursively [using data from yum, not rpm] if that is helpful:
 
 http://git.annexia.org/?p=febootstrap.git;a=blob;f=febootstrap_yum_rpm.ml;h=e70940df06edb87b616d739bf0912d742809842c;hb=HEAD#l38
 

repoquery --tree-requires ... should do that, but seems to be broken here,
whereas --tree-whatrequires works e.g.
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel


Re: A tool to list package deps sorted by buildtime?

2011-01-26 Thread Michael Schwendt
 repoquery --tree-requires ... [...] seems to be broken here,

Ah, it's just Adobe's packages that are broken and confuse the
depsolving. For example:

$ repoquery --whatprovides libgcc_s.so.1
libgcc-0:4.5.1-4.fc14.i686
AdobeReader_nor-0:8.1.7-1.i486
AdobeReader_ita-0:8.1.7-1.i486
AdobeReader_suo-0:8.1.7-1.i486
AdobeReader_kor-0:8.1.7-1.i486
AdobeReader_sve-0:8.1.7-1.i486
AdobeReader_dan-0:8.1.7-1.i486
AdobeReader_nld-0:8.1.7-1.i486
AdobeReader_chs-0:8.1.7-1.i486
AdobeReader_esp-0:8.1.7-1.i486
AdobeReader_ptb-0:8.1.7-1.i486
AdobeReader_cht-0:8.1.7-1.i486
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel


Re: A tool to list package deps sorted by buildtime?

2011-01-26 Thread seth vidal
On Wed, 2011-01-26 at 12:52 +0100, Michael Schwendt wrote:
 Scenario:
 
 Assume I have package foo. It's installed already, and the local RPM
 database covers it and all its dependencies.
 
 App foo used to run fine a month ago, but a rebuild no longer does.
 Dependencies have been updated. Too many for rpm -qa --last|less or
 yum's log to be helpful.
 
 I'd like to run an RPM query on foo that displays the %{buildtime}
 for all of foo's Requires, sorted by buildtime.
 
 Does anyone know of an existing tool that can do exactly this already?
 Or a script that achieves the same on top of an ordinary rpm --qf ... query?


I just want to make sure I have this:

1. rpm -qR foo

2. take each of those resolve it out to what provides them
3. return the buildtime + pkg name of each of those, sorted by buildtime

correct?

-sv


-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel


Re: A tool to list package deps sorted by buildtime?

2011-01-26 Thread seth vidal
On Wed, 2011-01-26 at 08:36 -0500, seth vidal wrote:
 On Wed, 2011-01-26 at 12:52 +0100, Michael Schwendt wrote:
  Scenario:
  
  Assume I have package foo. It's installed already, and the local RPM
  database covers it and all its dependencies.
  
  App foo used to run fine a month ago, but a rebuild no longer does.
  Dependencies have been updated. Too many for rpm -qa --last|less or
  yum's log to be helpful.
  
  I'd like to run an RPM query on foo that displays the %{buildtime}
  for all of foo's Requires, sorted by buildtime.
  
  Does anyone know of an existing tool that can do exactly this already?
  Or a script that achieves the same on top of an ordinary rpm --qf ... query?
 
 
 I just want to make sure I have this:
 
 1. rpm -qR foo
 
 2. take each of those resolve it out to what provides them
 3. return the buildtime + pkg name of each of those, sorted by buildtime
 
 correct?

If this is what you want then try:

http://skvidal.fedorapeople.org/misc/sort-req-by-buildtime.py

it'll be pretty simple to modify.

-sv


-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel


Re: A tool to list package deps sorted by buildtime?

2011-01-26 Thread seth vidal
On Wed, 2011-01-26 at 08:52 -0500, seth vidal wrote:
 On Wed, 2011-01-26 at 08:36 -0500, seth vidal wrote:
  On Wed, 2011-01-26 at 12:52 +0100, Michael Schwendt wrote:
   Scenario:
   
   Assume I have package foo. It's installed already, and the local RPM
   database covers it and all its dependencies.
   
   App foo used to run fine a month ago, but a rebuild no longer does.
   Dependencies have been updated. Too many for rpm -qa --last|less or
   yum's log to be helpful.
   
   I'd like to run an RPM query on foo that displays the %{buildtime}
   for all of foo's Requires, sorted by buildtime.
   
   Does anyone know of an existing tool that can do exactly this already?
   Or a script that achieves the same on top of an ordinary rpm --qf ... 
   query?
  
  
  I just want to make sure I have this:
  
  1. rpm -qR foo
  
  2. take each of those resolve it out to what provides them
  3. return the buildtime + pkg name of each of those, sorted by buildtime
  
  correct?
 
 If this is what you want then try:
 
 http://skvidal.fedorapeople.org/misc/sort-req-by-buildtime.py
 
 it'll be pretty simple to modify.

oh and  
 |sort -k2 


to sort by buildtime

-sv


-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel


Re: A tool to list package deps sorted by buildtime?

2011-01-26 Thread Michael Schwendt
On Wed, 26 Jan 2011 08:36:00 -0500, seth wrote:

 I just want to make sure I have this:
 
 1. rpm -qR foo
 
 2. take each of those resolve it out to what provides them
 3. return the buildtime + pkg name of each of those, sorted by buildtime
 
 correct?

Yes.

$ repoquery --qf '%{buildtime:isodate} %{name}-%{version}-%{release}.%{arch}' 
--requires --resolve glibc|sort|uniq
2009-07-24 21:41:21 basesystem-10.0-3.noarch
2010-09-12 19:11:32 nss-softokn-freebl-3.12.7-6.fc14.i686
2010-09-24 21:56:26 libgcc-4.5.1-4.fc14.i686
2010-12-14 17:03:44 glibc-2.12.90-21.i686
2011-01-20 10:52:15 glibc-2.13-1.i686
2011-01-20 10:52:15 glibc-common-2.13-1.i686
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel


Re: A tool to list package deps sorted by buildtime?

2011-01-26 Thread seth vidal
On Wed, 2011-01-26 at 16:40 +0100, Michael Schwendt wrote:
 On Wed, 26 Jan 2011 08:36:00 -0500, seth wrote:
 
  I just want to make sure I have this:
  
  1. rpm -qR foo
  
  2. take each of those resolve it out to what provides them
  3. return the buildtime + pkg name of each of those, sorted by buildtime
  
  correct?
 
 Yes.
 
 $ repoquery --qf '%{buildtime:isodate} %{name}-%{version}-%{release}.%{arch}' 
 --requires --resolve glibc|sort|uniq
 2009-07-24 21:41:21 basesystem-10.0-3.noarch
 2010-09-12 19:11:32 nss-softokn-freebl-3.12.7-6.fc14.i686
 2010-09-24 21:56:26 libgcc-4.5.1-4.fc14.i686
 2010-12-14 17:03:44 glibc-2.12.90-21.i686
 2011-01-20 10:52:15 glibc-2.13-1.i686
 2011-01-20 10:52:15 glibc-common-2.13-1.i686


Well that looks like a good use of repoquery, there. Nicely done.

-sv


-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel