[PLUG] Determining if Old Library Versions are Needed

chris (fool) mccraw gently at gmail.com
Mon Apr 6 20:18:55 UTC 2009


On Mon, Apr 6, 2009 at 13:15, chris (fool) mccraw <gently at gmail.com> wrote:
> On Mon, Apr 6, 2009 at 11:36, Jason Dagit <dagitj at gmail.com> wrote:
>> On Mon, Apr 6, 2009 at 11:32 AM, Rich Shepard <rshepard at appl-ecosys.com> wrote:
>>>   On my main box I have three versions of qt: -3.3.8b, -4.2.2, and -4.4.3.
>>> The last is the latest version and I use that to build new releases of apps
>>> requiring qt4 front ends.
>>>
>>>   Is there a clever way for me to determine if any currently installed apps
>>> use the two earlier versions? I'd just as soon delete the /usr/lib/
>>> directories for them if they're not required.
>>
>> Make sure to check both program binaries and .so files.  You wouldn't
>> want to miss something.  I don't know if this would be exhaustive but
>> it seems like a good place to start.  Although, it might take a while
>> to fully automate it.
>
> eh, not really.  i've been down this rabbit hole a few times:
>
>
> export VERSION=4.2.2
> find /bin /usr/bin /sbin /usr/sbin /usr/local/bin /usr/lib
> /usr/local/lib -type f > /tmp/list
> for i in `cat /tmp/list` ;
>  do file $i | grep ELF | grep shared && ldd $i | grep libqt | cut -d
> \> -f 2 |cut -d \( -f 1` | grep $VERSION && echo $i
> done

wow, that wrapped like crazy.  export, find, for, do and done should
be the only line-starters.



More information about the PLUG mailing list