I'd like to change dylib search path in a script. In the Terminal I use otool -L my.dylib, then see what is the search path and to change it use install_name_tool. The install_name_tool (-change) uses previous path and the new path as a arguments. How I can get result of otool -L to a script variable?
How I can get result of otool -L to a script variable?
Run otool from the script:
OUTPUT=$(otool -L /Applications/Calculator.app/Contents/MacOS/Calculator)
echo $OUTPUT