Sent from my T-Mobile 4G LTE Device
-------- Original message --------From: Ben Koenig <[email protected]> Date: 
3/22/18  10:44 AM  (GMT-08:00) To: Portland Linux/Unix Group 
<[email protected]> Subject: Re: [PLUG] Command to find applications dependent 
on named library 
https://slackbuilds.org/slackbuilds/14.2/SLACKBUILDS.TXT

#!/bin/sh
PKG=$1
wget https://slackbuilds.org/slackbuilds/14.2/SLACKBUILDS.TXT
echo "-- For $PKG -- "
cat SLACKBUILDS.TXT | grep -A10 "NAME: $1$" |grep REQUIRES

#cleanup
rm SLACKBUILDS.TXT

It takes a second to download the txt file. Every script contains an info
file with 10 lines. extract, and return whatever is listed after REQUIRES.
Credit to the SBo homepage for providing links to their internal data.


On Thu, Mar 22, 2018 at 9:21 AM, Galen Seitz <[email protected]> wrote:

> On 03/22/2018 08:23 AM, Rich Shepard wrote:
>
>> On Thu, 22 Mar 2018, Ben Koenig wrote:
>>
>> Slackware:
>>> - Responsibility of the user
>>> - by default nothing in slackware has the capability to record
>>> dependencies.
>>> - You would keep track of this manually, or install an extra tool.
>>> - rpm is installed by default, however since no packages were installed
>>> via
>>> rpm it has no knowledge of what is installed
>>>
>>
>> Ben,
>>
>>    I thought there might be a generic linux tool equivalent to ldd. My
>> specific interest is with SlackBuilds.org packages and I suspect there's a
>> way of searching the repo for this information in each package's info
>> file.
>> It's likely that one of the package maintainers will suggest a search
>> protocol.
>>
>
> You could brute force it using something like this:
>
> find /usr/bin -type f -executable -print0 | xargs -0 -t ldd | grep
> mylibtofind > results.txt 2>&1
>
> The -t on the xargs command will cause it to output each ldd command to
> stderr.  You would then need to scan the results.txt file to find those
> commands that resulted in output from grep.  There's probably a better way
> to do this, but I think this should work.  It's untested, of course.
>
>
> galen
> --
> Galen Seitz
> [email protected]
>
> _______________________________________________
> PLUG mailing list
> [email protected]
> http://lists.pdxlinux.org/mailman/listinfo/plug
>
_______________________________________________
PLUG mailing list
[email protected]
http://lists.pdxlinux.org/mailman/listinfo/plug
_______________________________________________
PLUG mailing list
[email protected]
http://lists.pdxlinux.org/mailman/listinfo/plug

Reply via email to