在mac下开发该如何配置dylib
输入如下的指令后
otool -L imageInterpolation.app/Contents/MacOS/imageInterpolation
得知openCV的dylib的identification name是
lib/libopencv_core.2.4.dylib (compatibility version 2.4.0, current version 2.4.3)
然后我写了一个改变identification name的script
[code=c]
#!/bin/bash
mkdir /Users/Qt/program/commercial_apps/imageInterpolation/imageInterpolation.app/Contents/Frameworks
cp /usr/local/lib/libopencv_core.2.4.3.dylib /Users/Qt/program/commercial_apps/imageInterpolation/imageInterpolation.app/Contents/Frameworks
install_name_tool -id @executable_path/../Frameworks/libopencv_core.2.4.3.dylib /Users/Qt/program/commercial_apps/imageInterpolation/imageInterpolation.app/Contents/Frameworks/libopencv_core.2.4.3.dylib
[/code
很遗憾的是identification的名字还是没有改变
执行otool后结果还是一样
好像还得配合install_name_tool的另外一个选项,-change
不过我不晓得该怎么用
[解决办法]
可以分享在你的blog中了。
[解决办法]
自己回复了也没有问题,而且原分全部返还
[解决办法]
MAC下还还没接触过呢