From 17a15ca38fbf6e219d993eadf3e0ceb6222f4314 Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Sun, 4 May 2008 09:14:18 +0000 Subject: [PATCH] Also store the install_name, we need it to detect the group of files/symlinks that make up one library svn path=/main/branches/prefix/; revision=10173 --- bin/misc-functions.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/bin/misc-functions.sh b/bin/misc-functions.sh index bf1606ad1..cc4fb8894 100644 --- a/bin/misc-functions.sh +++ b/bin/misc-functions.sh @@ -375,11 +375,15 @@ install_qa_check() { rm -f "${T}"/.install_name_check_failed [[ ${CHOST} == *-darwin* ]] && find "${ED}" -type f | while IFS= read f ; do rm -f "${T}"/.NEEDED.tmp + install_name=$(otool -DX "${f}") otool -LX "${f}" \ | grep -v "Archive : " \ | sed -e 's/^\t//' -e 's/ (compa.*$//' \ | while read r ; do + # skip the self reference in libraries + [[ -n ${install_name} && ${install_name} == ${r} ]] && continue + if [[ ! -e ${r} && ! -e ${D}${r} && ${r} != *"@executable_path"* ]] ; then # try to "repair" this if possible, happens because of # gen_usr_ldscript tactics @@ -401,7 +405,7 @@ install_qa_check() { done if [[ -f "${T}"/.NEEDED.tmp ]] ; then needed=$(< "${T}"/.NEEDED.tmp) - echo "/${f#${D}};${needed#,}" >> "${PORTAGE_BUILDDIR}"/build-info/NEEDED.MACHO.2 + echo "/${f#${D}};${install_name};${needed#,}" >> "${PORTAGE_BUILDDIR}"/build-info/NEEDED.MACHO.2 fi done if [[ -f ${T}/.install_name_check_failed ]] ; then -- 2.26.2