Add a -v to tell where each symbol is resolved from.

Sponsored by:	EMC / Isilon Storage Division
This commit is contained in:
bdrewery 2015-05-01 05:01:56 +00:00
parent d51ae46807
commit 915a417616

View File

@ -20,9 +20,11 @@ libkey() {
ret=0
CHECK_UNRESOLVED=1
while getopts "U" flag; do
VERBOSE_RESOLVED=0
while getopts "Uv" flag; do
case "${flag}" in
U) CHECK_UNRESOLVED=0 ;;
v) VERBOSE_RESOLVED=1 ;;
esac
done
shift $((OPTIND-1))
@ -91,7 +93,12 @@ if [ ${CHECK_UNRESOLVED} -eq 1 ]; then
eval "lib_symbols=\"\${${libkey}}\""
# lib_symbols now contains symbols for the lib.
case " ${lib_symbols} " in
*\ ${sym}\ *) found=1 && break ;;
*\ ${sym}\ *)
[ ${VERBOSE_RESOLVED} -eq 1 ] &&
echo "Resolved symbol ${sym} from ${lib}"
found=1
break
;;
esac
done
if [ $found -eq 0 ]; then