File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -531,9 +531,9 @@ function relocate() {
531531 while read -r file; do
532532 if old_rpath="$(patchelf --print-rpath "${file}" 2>/dev/null)"; then
533533 if ${overwrite}; then
534- old_rpath="\$ORIGIN:\$ORIGIN/lib :\$ORIGIN/lib64 :\$ORIGIN/../lib :\$ORIGIN/../lib64 "
534+ old_rpath="\$ORIGIN:\$ORIGIN/lib64 :\$ORIGIN/lib :\$ORIGIN/../lib64 :\$ORIGIN/../lib "
535535 fi
536- new_rpath="${old_rpath:+${old_rpath}:}${library_path }"
536+ new_rpath="${library_path}${ old_rpath:+: ${old_rpath}}"
537537 patchelf --set-rpath "${new_rpath}" "${file}"
538538 if readelf -S "${file}" | grep ' .interp' >/dev/null; then
539539 patchelf --set-interpreter "${interpreter}" "${file}"
@@ -625,13 +625,13 @@ function configure_toolchain() {
625625 popd >/dev/null || exit
626626
627627 local rpaths=(
628+ "$(pwd)/$(uname -m)-linux-gnu/lib"
629+ "$(dirname "${libc_so}")"
628630 "\$ORIGIN"
629- "\$ORIGIN/lib"
630631 "\$ORIGIN/lib64"
631- "\$ORIGIN/../ lib"
632+ "\$ORIGIN/lib"
632633 "\$ORIGIN/../lib64"
633- "$(pwd)/$(uname -m)-linux-gnu/lib"
634- "$(dirname "${libc_so}")"
634+ "\$ORIGIN/../lib"
635635 )
636636 local rpaths_in_line
637637 rpaths_in_line="$(
You can’t perform that action at this time.
0 commit comments