我正在开发一个32位软件的插件。 编码过程几乎完成,但为了测试它,我必须将我的插件加载到软件中。
编译时没有警告/错误,但插件不会加载。
使用mac控制台日志,我发现错误是:
(?=(?:[^\[\]]|\[[^\[\]]*\])*\])
我尝试将架构(构建设置)更改为
> 17/08/2015 12:04:51,271 Hidden[7518]: Error loading
> /Library/Application
> Support/Hidden/Plugins/MultiUsersPreferences.hiddenplugin/Contents/MacOS/MultiUsersPreferences:
> dlopen(/Library/Application
> Support/Hidden/Plugins/MultiUsersPreferences.hiddenplugin/Contents/MacOS/MultiUsersPreferences,
> 265): no suitable image found. Did find: /Library/Application
> Support/Hidden/Plugins/MultiUsersPreferences.hiddenplugin/Contents/MacOS/MultiUsersPreferences:
> mach-o, but wrong architecture
但同样的错误让poppin'起来了。
到目前为止,我没有找到任何正确的解决方案,我不知道Xcode足以让我自己做,有人能给我一个提示吗?
感谢。
答案 0 :(得分:1)
在项目设置中,将架构设置为32位:
使用' file'命令,您可以检查二进制的体系结构。例如:
$ file /Applications/Calculator.app/Contents/MacOS/Calculator
/Applications/Calculator.app/Contents/MacOS/Calculator: Mach-O 64-bit executable x86_64
答案 1 :(得分:0)
或者,将“仅构建活动体系结构”更改为“否”。您可能正在构建一个调试版本,默认情况下,它在64位计算机上只构建一个64位的片段。