From 73dab0587b0b687546e8964544513a96bac9d656 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Mon, 8 Mar 2010 10:47:25 +0100 Subject: [PATCH] verify_rundeps: handle same shlib provided by multiple pkgs. --HG-- extra : convert_revision : 5d021d453acd0fdf440cbafbec89613340e9e349 --- xbps-src/shutils/verify_rundeps.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/xbps-src/shutils/verify_rundeps.sh b/xbps-src/shutils/verify_rundeps.sh index 83e615e4d3..3d06e5f014 100644 --- a/xbps-src/shutils/verify_rundeps.sh +++ b/xbps-src/shutils/verify_rundeps.sh @@ -92,12 +92,21 @@ verify_rundeps() for f in ${verify_deps}; do # Bail out if maplib is not aware for this lib rdep="$(grep "$f" $maplib|awk '{print $2}')" + rdepcnt="$(grep "$f" $maplib|awk '{print $2}'|wc -l)" if [ -z "$rdep" ]; then msg_error_nochroot "unknown rundep for $f" fi # Ignore libs by current pkg [ "$rdep" = "$pkgname" ] && continue + # Check if shlib is provided by multiple pkgs. + if [ "$rdepcnt" -gt 1 ]; then + echo "=> Required $f is provided by these pkgs: " + for j in ${rdep}; do + printf "\t$j\n" + done + continue + fi # Warn if rundep is not in template. if find_rundep "$rdep"; then msg_warn_nochroot "required $f from $rdep (MISSING)" @@ -131,8 +140,13 @@ verify_rundeps() for f in ${missing_libs}; do rdep="$(grep "$f" $maplib|awk '{print $2}')" + rdepcnt="$(grep "$f" $maplib|awk '{print $2}'|wc -l)" builddep="$(grep "$f" $maplib|awk '{print $3}')" + # If required shlib is provided by multiple pkgs pass + # to next one. + [ "$rdepcnt" -gt 1 ] && continue + if [ -z "$rdep_list" ]; then rdep_list="$rdep" fi