mkvtoolnix/packaging/macos/fix_library_paths.sh

16 lines
284 B
Bash
Raw Permalink Normal View History

#!/bin/zsh
while [[ -n $1 ]]; do
FILE=$1
shift
otool -L ${FILE} | \
grep -v : | \
grep -v @executable_path | \
awk '/libQt/ { print $1 }' | { \
while read LIB ; do
install_name_tool -change ${LIB} @executable_path/libs/${LIB:t} ${FILE}
done
}
done