Cocos2d-x   发布时间:2022-05-03  发布网站:大佬教程  code.js-code.com
大佬教程收集整理的这篇文章主要介绍了cocos2dx3.2 Other Linker Flags 设置成 -ObjC 真机编译报错大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。


Undefined symbols for architecture armv7s:

"_GCControllerDidDisconnectNotification",referenced from:
-[GCControllerConnectionEventHandler observerConnection:disconnection:] in libcocos2dx iOs.a(CCController-iOs.o)
"_GCControllerDidConnectNotification",serif; font-size:14px; line-height:24px"> "_OBJC_CLASS_$_GCController",serif; font-size:14px; line-height:24px"> objc-class-ref in libcocos2dx iOs.a(CCController-iOs.o)
(maybe you meant: _OBJC_CLASS_$_GCControllerConnectionEventHandler)
ld: symbol(s) not found for architecture armv7s
clang: error: linker command failed with exit code 1 (use -v to see invocation)

我用的是iphone5c,昨天使用admob的广告,这个sdk要求要将Other Linker Flags 设置成 -ObjC。不知如何解决以上报错。


解决方法:

增加两个库:
@H_703_7@mediaPlayer.framework

GameController.framework


原因参见:http://stackoverflow.com/questions/24844766/linking-errors-when-adding-admob-to-ios-cocos2d-x-3-2

大佬总结

以上是大佬教程为你收集整理的cocos2dx3.2 Other Linker Flags 设置成 -ObjC 真机编译报错全部内容,希望文章能够帮你解决cocos2dx3.2 Other Linker Flags 设置成 -ObjC 真机编译报错所遇到的程序开发问题。

如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。