summaryrefslogtreecommitdiff
path: root/packaging
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2013-10-09 20:49:12 +0000
committerGerald Combs <gerald@wireshark.org>2013-10-09 20:49:12 +0000
commit6a8ceca13aaf50c7da0c5640eaef5f6f60b48b38 (patch)
treecf764eaf9e2290fd60bbab36e1f2ccb87f38f311 /packaging
parent51d6f57fd7d72ee70bd2ee9e70151a8c7e79bfc1 (diff)
downloadwireshark-6a8ceca13aaf50c7da0c5640eaef5f6f60b48b38.tar.gz
Sometimes we need to @rpathify libraries from more than one directory.
Instead of trying to match libraries from $LIBPREFIX, exclude libraries that aren't in well-known system paths and which haven't previously been @rpathified. svn path=/trunk/; revision=52479
Diffstat (limited to 'packaging')
-rwxr-xr-xpackaging/macosx/osx-app.sh29
1 files changed, 23 insertions, 6 deletions
diff --git a/packaging/macosx/osx-app.sh b/packaging/macosx/osx-app.sh
index 9b58ff5fb4..8af092c340 100755
--- a/packaging/macosx/osx-app.sh
+++ b/packaging/macosx/osx-app.sh
@@ -43,6 +43,8 @@ plist="./Info.plist"
util_dir="./Utilities"
cli_dir="$util_dir/Command Line"
chmodbpf_dir="$util_dir/ChmodBPF"
+exclude_prefixes="/System/|/Library/|/usr/lib/|/usr/X11/|/opt/X11/|@rpath|@executable_path"
+
# "qt" or "gtk"
ui_toolkit="gtk"
@@ -413,7 +415,14 @@ fi
while $endl; do
echo -e "Looking for dependencies. Round" $a
- libs="`otool -L $lib_dep_search_list 2>/dev/null | fgrep compatibility | cut -d\( -f1 | grep $LIBPREFIX | sort | uniq`"
+ libs="`\
+ otool -L $lib_dep_search_list 2>/dev/null \
+ | fgrep compatibility \
+ | cut -d\( -f1 \
+ | egrep -v "$exclude_prefixes" \
+ | sort \
+ | uniq \
+ `"
cp -vn $libs "$pkglib"
let "a+=1"
nnfiles=`ls "$pkglib" | wc -l`
@@ -482,7 +491,15 @@ rpathify_file () {
# system on which the bundle will be installed,
# and should be referred to by their full pathnames.
#
- libs="`otool -L $1 | egrep "$LIBPREFIX.* \(compatibility" | cut -d\( -f1`"
+ libs="`\
+ otool -L $1 \
+ | fgrep compatibility \
+ | cut -d\( -f1 \
+ | egrep -v "$exclude_prefixes" \
+ | sort \
+ | uniq \
+ `"
+
for lib in $libs; do
#
# Get the file name of the library.
@@ -541,6 +558,10 @@ rpathify_files () {
rpathify_dir "$pkgbin" "*"
}
+if [ "$ui_toolkit" = "qt" ] ; then
+ macdeployqt "$package" -verbose=2
+fi
+
PATHLENGTH=`echo $LIBPREFIX | wc -c`
if [ "$PATHLENGTH" -ge "6" ]; then
# If the LIBPREFIX path is long enough to allow
@@ -558,8 +579,4 @@ else
fi
-if [ "$ui_toolkit" = "qt" ] ; then
- macdeployqt "$package" -verbose=2
-fi
-
exit 0