From 7f21e75135386c022cba2703ab553868c9483723 Mon Sep 17 00:00:00 2001 From: David Dawes Date: Sat, 16 Jun 2018 11:01:49 -0700 Subject: [PATCH] Clean up makeRelease more. --- makeRelease.sh | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/makeRelease.sh b/makeRelease.sh index 8a3696d4a..700961a83 100755 --- a/makeRelease.sh +++ b/makeRelease.sh @@ -23,11 +23,16 @@ for binary in "${libraries[@]}"; do # Need to undo this for the dylibs when we are done chmod 755 $KMD_DIR/$binary - # find the dylibs to copy for komodod + # find the dylibs to copy for komodod DYLIBS=`otool -L $KMD_DIR/$binary | grep "/usr/local" | awk -F' ' '{ print $1 }'` - echo "copying $DYLIBS to $KMD_DIR" + echo "copying indirect $DYLIBS to $KMD_DIR" # copy the dylibs to the srcdir for dylib in $DYLIBS; do cp -rf $dylib $KMD_DIR; done + echo "modifying komodod to use local libraries" + for dylib in $DYLIBS; do install_name_tool -change $dylib @executable_path/`basename $dylib` $KMD_DIR/komodod; done; + chmod +x $KMD_DIR/komodod + for dylib in $DYLIBS; do install_name_tool -change $dylib @executable_path/`basename $dylib` $KMD_DIR/komodo-cli; done; + chmod +x $KMD_DIR/komodo-cli done indirectlibraries=("libintl.8.dylib" "libunistring.2.dylib") @@ -41,5 +46,11 @@ do echo "copying $DYLIBS to $KMD_DIR" # copy the dylibs to the srcdir for dylib in $DYLIBS; do cp -rf $dylib $KMD_DIR; done + # fix binary references to it + echo "modifying komodod to use local libraries" + for dylib in $DYLIBS; do install_name_tool -change $dylib @executable_path/`basename $dylib` $KMD_DIR/komodod; done; + chmod +x $KMD_DIR/komodod + for dylib in $DYLIBS; do install_name_tool -change $dylib @executable_path/`basename $dylib` $KMD_DIR/komodo-cli; done; + chmod +x $KMD_DIR/komodo-cli done