From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from h5331.serverkompetenz.net (h5331.serverkompetenz.net [81.169.174.146]) by robin.gentoo.org (8.13.4/8.13.4) with ESMTP id j3NCDqbG020441 for ; Sat, 23 Apr 2005 12:13:53 GMT Received: from h5331.serverkompetenz.net (localhost [127.0.0.1]) by h5331.serverkompetenz.net (8.12.10/8.12.10) with ESMTP id j3NCDNBb012660 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Sat, 23 Apr 2005 14:13:23 +0200 Received: (from juergen@localhost) by h5331.serverkompetenz.net (8.12.10/8.12.10/Submit) id j3NCDMgE012659 for gentoo-dev@lists.gentoo.org; Sat, 23 Apr 2005 14:13:22 +0200 Date: Sat, 23 Apr 2005 14:13:22 +0200 From: Juergen Hoetzel To: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] Reverse dependency Scanning Message-ID: <20050423121322.GA12478@h5331.serverkompetenz.net> References: <1114251333.619.9.camel@Darkmere> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@gentoo.org Reply-to: gentoo-dev@lists.gentoo.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1114251333.619.9.camel@Darkmere> User-Agent: Mutt/1.5.6i X-Archives-Salt: ffb2cc58-82c7-4e7d-90e0-afa83daf8e47 X-Archives-Hash: 2b1f1a4e939a1c9803ceb5553d086a84 Why not reverse it: 1. *DONT* unmerge an old lib (the *.so.* file) if the soname changes due an upgrade. Just leave this single file on the file-system 2. Scan your system in regular intervals for unused old shared libs This seems much simpler and doesn't break systems. Jürgen > Well, this is something I spent quite a bit of time on yesterday, with > some help from bonsaikitten on figuring out the python madness. > > > Before ferringb tells it again, no, I know this isn't foolproof, cannot > be 100% in coverage, won't cover dlopen, conditional includes, bash > source inherit or other such fancy things that people do :) > > However, it somewhat works ;) > What it does : > given a list of files ( `etcat files category/package` generates a > nice one ) it scans them, classifies into "scripts, perl, python, > libraries, executables" , then does its best to parse theese into > generating a list of -needed- files. > > This means that it outputs a list of shared libraries linked against, > python modules imported, perl modules, and script interpreters > ( #!/bin/bash ...) > > So, taking that list you can then play around a bit with `qpkg -f` and > you'll end up with a nice list of packages that are actually used. > > > So, I know it isn't foolproof, don't expect it to be. However, feedback > would be nice, patches and so on. > > oh, where it lives? cvs : gentoo/users/spider/depreverse , expects to > be ran from the current directory as it calls "./..." for the included > scripts. > > http://www.gentoo.org/cgi-bin/viewcvs.cgi/users/spider/depreverse/?root=gentoo > > > //Spider > > > -- > begin .signature > Tortured users / Laughing in pain > See Microsoft KB Article Q265230 for more information. > end > -- gentoo-dev@gentoo.org mailing list