3 binaries=("komodo-cli" "komodod")
5 for binary in "${binaries[@]}";
7 # find the dylibs to copy for komodod
8 DYLIBS=`otool -L src/$binary | grep "/usr/local" | awk -F' ' '{ print $1 }'`
9 echo "copying $DYLIBS to $src"
10 # copy the dylibs to the srcdir
11 for dylib in $DYLIBS; do cp -rf $dylib src/; done
13 # modify komodod to point to dylibs
14 echo "modifying $binary to use local libraries"
15 for dylib in $DYLIBS; do install_name_tool -change $dylib @executable_path/`basename $dylib` src/$binary; done;