xbps-src: faster 'show-revdeps' impl for shlibs.
This commit is contained in:
parent
e1b20273e6
commit
dd608bb73b
|
@ -45,15 +45,18 @@ _show_shlib_pkg_deps()
|
|||
{
|
||||
local f j
|
||||
|
||||
for f in $(find ${XBPS_SRCPKGDIR} -type f -name *.rshlibs); do
|
||||
for j in ${1}; do
|
||||
if grep -q "$j" "$f"; then
|
||||
revdepname=$(basename $f)
|
||||
echo "${revdepname%.rshlibs}"
|
||||
break
|
||||
revshlibs=$(grep "$1" ${XBPS_SRCPKGDIR}/*/*.rshlibs)
|
||||
for f in ${revshlibs}; do
|
||||
unset pkg revdepname tmprev
|
||||
revdepname=$(basename "$f")
|
||||
revdepname=${revdepname%.rshlibs*}
|
||||
tmprev=$(echo "$revdepname"|sed 's/-//g')
|
||||
eval pkg=\$pkg_"${tmprev}"
|
||||
if [ -z "${pkg}" ]; then
|
||||
eval local pkg_${tmprev}=1
|
||||
echo "$revdepname"
|
||||
fi
|
||||
done
|
||||
done
|
||||
}
|
||||
|
||||
show_pkg_revdeps()
|
||||
|
@ -62,7 +65,7 @@ show_pkg_revdeps()
|
|||
|
||||
[ -z "$1" ] && return 1
|
||||
|
||||
shlibs=$(grep "$1" $SHLIBS_MAP)
|
||||
shlibs=$(grep "$1" $SHLIBS_MAP|awk '{print $1}')
|
||||
if [ -n "$shlibs" ]; then
|
||||
# pkg provides shlibs
|
||||
_show_shlib_pkg_deps "$shlibs"
|
||||
|
|
Loading…
Reference in New Issue