gpt4 book ai didi

ios - 如何将 ObjCMongoDb 集成到 iOS 应用程序中?

转载 作者:行者123 更新时间:2023-11-29 03:41:48 24 4
gpt4 key购买 nike

因此,我尝试在 iOS 应用程序中启动并运行 ObjCMongoDb,但我一直收到此错误。

ignoring file /Users/user/Documents/Programming/ObjCMongoDB/ObjCMongoDB.framework/ObjCMongoDB, file was built for unsupported file format ( 0xcf 0xfa 0xed 0xfe 0x 7 0x 0 0x 0 0x 1 0x 3 0x 0 0x 0 0x 0 0x 6 0x 0 0x 0 0x 0 ) which is not the architecture being linked (armv7): /Users/user/Documents/Programming/ObjCMongoDB/ObjCMongoDB.framework/ObjCMongoDB
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_BSONDecoder", referenced from:
objc-class-ref in MongoDbConnection.o
"_OBJC_CLASS_$_MongoKeyedPredicate", referenced from:
objc-class-ref in MongoDbConnection.o
"_OBJC_CLASS_$_MongoUpdateRequest", referenced from:
objc-class-ref in MongoDbConnection.o
"_OBJC_CLASS_$_MongoConnection", referenced from:
objc-class-ref in MongoDbConnection.o
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)

我有一种感觉,这意味着该框架不是为 iOS 而是为 Mac OS X 编译的。

有谁知道如何将 ObjCMongoDb 集成到 iOS 应用程序中?

谢谢!

最佳答案

要在 iOS 上使用框架,您需要将其构建为静态库,而属于 ObjCMongoDB 一部分的 Xcode 项目没有提供这样做的方法。

最简单的方法是按照 getting started on Mac OS 的说明进行操作,这在 iOS 上应该同样有效。

关于ios - 如何将 ObjCMongoDb 集成到 iOS 应用程序中?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18325533/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com