apply "new style provides" rules for sonameless libraries too.

This commit is contained in:
Дмитрий Левин 2006-02-23 00:43:25 +00:00
parent 8c87828ea8
commit 783e7d2896

View File

@ -268,13 +268,13 @@ FindLibProvs()
soname="$(printf %s\\n "$dump" |sed -ne 's/^[[:space:]]*SONAME[[:space:]]\+\([^[:space:]]\+\)[[:space:]]*$/\1/p')" || return 1
suffix="$(printf %s\\n "$dump" |sed -ne 's/^.*file format \(elf64\).*$/(64bit)/p')" || return 1
[ -z "$suffix" ] && braces= || braces='()'
if [ -n "$soname" ]; then
while :; do
# For libraries with soname, ignore all but files named as soname.
[ "$soname" = "$name" ] || break
[ -z "$soname" -o "$soname" = "$name" ] || break
# Treat symlinks specially.
if [ -L "$f" ]; then
[ -n "$soname" ] || break
local real realpath realdir
realpath=$(readlink -fv "$f") || break
real="${realpath#$real_buildroot}"
@ -285,6 +285,9 @@ FindLibProvs()
[ "${#dir}" -le "${#realdir}" ] || break
fi
# soname is either empty or equal to name
soname="$name"
# Check for non-default path.
local nondefdir=
lookup_path "$dir" "$DEF_RPM_FINDPROV_LIB_PATH" || nondefdir="$dir"
@ -311,10 +314,6 @@ FindLibProvs()
break
done
else
# Ignore symlinks for libraries without soname.
[ -L "$f" ] || printf %s\\n "${f##*/}$braces$suffix"
fi
fi
}