summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorgoro <qtc-committer@nokia.com>2009-01-22 17:07:45 +0100
committergoro <qtc-committer@nokia.com>2009-01-22 17:13:40 +0100
commit24b08b11a50bbccb7628c427f93b43bf2734decc (patch)
treecfd9a074b5f7b1a729998c9b544846a03dbbf0d3 /scripts
parentf571457523d2986687017a8469ce4173fe46ec99 (diff)
downloadqt-creator-24b08b11a50bbccb7628c427f93b43bf2734decc.tar.gz
Update rpath handling
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/shipping/prepare-linux-qt-for-shipping.sh32
1 files changed, 6 insertions, 26 deletions
diff --git a/scripts/shipping/prepare-linux-qt-for-shipping.sh b/scripts/shipping/prepare-linux-qt-for-shipping.sh
index 4d624ff538..869f0e837f 100755
--- a/scripts/shipping/prepare-linux-qt-for-shipping.sh
+++ b/scripts/shipping/prepare-linux-qt-for-shipping.sh
@@ -76,20 +76,6 @@ build() {
ret=$?; [ ${ret} = 0 ] || exit ${ret}
}
-fix_rpath() {
- folder=$1
- pattern=$2
- rpath=$3
- (
- cd "${destdir}" || die "cd failed"
- while read file ; do
- echo "Fixing ${file}"
- chrpath -r "${rpath}" "${file}" 2>&1 | sed 's/^/\t/'
- done < <(find "${folder}" -type f -name "${pattern}")
- )
- ret=$?; [ ${ret} = 0 ] || exit ${ret}
-}
-
inst() {
(
cd "${dir}" || die "cd failed"
@@ -98,19 +84,13 @@ inst() {
env -i "${MAKE}" install || die "make install failed"
fi
+ # Fix rpath's
cd "${destdir}" || die "cd failed"
-
- # Fix files bin/*
- fix_rpath bin '*' '$ORIGIN/../lib'
-
- # Fix files lib/*.so
- fix_rpath lib '*.so.?.?.?.debug' '$ORIGIN'
-
- # Fix files examples/tools/*/*/*.so
- fix_rpath examples/tools '*.so' '$ORIGIN/../../../lib'
-
- # Fix files plugins/*/*.so
- fix_rpath plugins '*.so' '$ORIGIN/../../lib'
+ find bin -mindepth 1 -maxdepth 1 -type f -perm -100 | xargs -n 1 chrpath -r '$ORIGIN/../lib'
+ find lib -mindepth 1 -maxdepth 1 -type f -perm -100 | xargs -n 1 chrpath -r '$ORIGIN'
+ find . -mindepth 3 -maxdepth 3 -type f -perm -100 | xargs -n 1 chrpath -r '$ORIGIN/../../lib'
+ find . -mindepth 4 -maxdepth 4 -type f -perm -100 | xargs -n 1 chrpath -r '$ORIGIN/../../../lib'
+ find . -mindepth 5 -maxdepth 5 -type f -perm -100 | xargs -n 1 chrpath -r '$ORIGIN/../../../../lib'
)
ret=$?; [ ${ret} = 0 ] || exit ${ret}
}