aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorYorkie Liu <yazhong.liu@rokid.com>2018-12-10 17:35:32 +0800
committerJo-Philipp Wich <jo@mein.io>2018-12-19 15:36:05 +0100
commit8b2efc87dbf2a194c7d8afccf36a3f9f73854170 (patch)
treee7d99844921fbdbd39b627edbdfe27dc0dc5ffd1 /scripts
parent386803a006edafd54cef20b4b99b033b1b52cf5c (diff)
downloadupstream-8b2efc87dbf2a194c7d8afccf36a3f9f73854170.tar.gz
upstream-8b2efc87dbf2a194c7d8afccf36a3f9f73854170.tar.bz2
upstream-8b2efc87dbf2a194c7d8afccf36a3f9f73854170.zip
scripts: rstrip.sh: allow rpath with sole $ORIGIN token
2efe776 introduces rpath checks with the commit message: > Remove all rpath entries which do not point to a location below /lib or > /usr/lib and which do not begin with '$ORIGIN'. However the implementation failed to support rpath entries with only the '$ORIGIN' token and no trailing slash, so allow these as well. Signed-off-by: Yorkie Liu <yazhong.liu@rokid.com> [reword commit message] Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/rstrip.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/rstrip.sh b/scripts/rstrip.sh
index 55caefc1a8..59f8624df2 100755
--- a/scripts/rstrip.sh
+++ b/scripts/rstrip.sh
@@ -34,7 +34,7 @@ find $TARGETS -type f -a -exec file {} \; | \
old_rpath="$($PATCHELF --print-rpath $F)"; new_rpath=""
for path in $old_rpath; do
case "$path" in
- /lib/[^/]*|/usr/lib/[^/]*|\$ORIGIN/*) new_rpath="${new_rpath:+$new_rpath:}$path" ;;
+ /lib/[^/]*|/usr/lib/[^/]*|\$ORIGIN/*|\$ORIGIN) new_rpath="${new_rpath:+$new_rpath:}$path" ;;
*) echo "$SELF: $F: removing rpath $path" ;;
esac
done