On Mon, Apr 13, 1998 at 01:59:16PM -0400, Ossama Othman wrote: > Hi Rob, > > > On a related note, is there a program that can keep a record of the > > most heavily used libraries and programs, so that a list could be made > > of the most useful ones to recompile? > > I am not aware of any program that will do that. The only thing I can > think of is to use ldd to see what libraries are being used by the > programs you want to recompile. Perhaps someone on the Debian list knows > better. > > -Ossama > ldd <program name> gives you the list of libraries a program you find slow depends on; dpkg -S <library> gives you the package from which belongs the library pkg-revdeps <package> gives you the packages dependencies tree on which a <package> depends. pkg-deptree <package> gives you the packages tree of which packages depends on <package> Than I think that you need is pkg-deptree <package> | depcount where depcount is this file: -----------8x-------------- #!/usr/bin/awk -f /^ / { x++ } /^[^ ]/ { if (pkg != "") { print x } ; \ printf "%s ", $0 ; x = 0 ; pkg = $0 } END { print x } -----------8x-------------- This not gives a perfect representation because pkg-deptree don't repeat already list package. Exemple: pkg-deptree libc5 xpm4.7 | depcount will give: libc5 27 xpm4.7 0 although xpm4.7 has has 4 packages dependencies on my system. That because xpm4.7 depends himself from libc5 than all packages who depends on xpm4.7 are allready list in libc5 and not reprint. So, only put one package by run to get a correct list [it's a bit long also]. BTW, pkg-* are in pkg-order. -- ------------------------------------------------------------------------ Fabien Ninoles Running Debian/GNU Linux E-mail: fab@tzone.org WebPage: http://www.callisto.si.usherb.ca/~94246757 WorkStation [available when connected!]: http://nightbird.tzone.org/ RSA PGP KEY [E3723845]: 1C C1 4F A6 EE E5 4D 99 4F 80 2D 2D 1F 85 C1 70 ------------------------------------------------------------------------
Attachment:
pgpLVNEKaTEjL.pgp
Description: PGP signature