“用于架构arm64的未定义符号";使用Firebase C ++ SDK时 [英] "Undefined symbols for architecture arm64" when using Firebase C++ sdk
问题描述
我下载了Firebase C ++ SDK,2016年6月10日.我将sdk添加到我的iOS项目中,将-objc设置为其他链接器标志.而且我有一个链接器错误请咨询.
I downloaded the firebase c++ sdk, 10 jun 2016. I added the sdk into my iOS project, set the -objc into the other linker flags. And i got a linker error PLease advice.
错误日志如下:
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_FIRApp", referenced from:
objc-class-ref in libapp.a(app_ios_efc96a6f6f98f7443dddf841f7396489.o)
"_OBJC_CLASS_$_FIROptions", referenced from:
objc-class-ref in libapp.a(app_ios_efc96a6f6f98f7443dddf841f7396489.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
(编辑1)框架搜索路径:
(EDIT 1) Framework search path:
$(PROJECT_DIR)/ios/Libs/Firebase
firebase位于文件夹中,并且包含和.a库.
The firebase is in the folder and the includes and the .a libraries.
推荐答案
当我遇到相同的错误时,我的问题是我没有在C ++库中包含iOS SDK.我没有意识到iOS SDK上的C ++库DEPENDS.
My problem when I got the same error was that I did not include the iOS SDK along with the C++ library. I did not realize that the C++ library DEPENDS on iOS SDK.
我认为C ++库是一个全新的代码库,为跨平台开发提供了潜力.但是,您仍然只限于iOS或Android,但可以选择使用C ++进行编码,以便可以在iOS和Android中重用C ++代码.
I thought that the the C++ library is a whole new code base that provides the potential for cross-platform development. However, you are still bound to only iOS or Android, but you can choose to code in C++ so you could reuse the C++ code in iOS and Android.
这篇关于“用于架构arm64的未定义符号";使用Firebase C ++ SDK时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!