iphone - iOS 5、Xcode 4.2 和 ProtoBuf

标签 iphone ios xcode xcode4.2 protocol-buffers

我正在尝试编译 google protobuf 协议(protocol)以便在我的 iOS 5 项目中使用它,但还没有成功...我只找到一篇关于该主题的博客文章 here .但是当我尝试这种方法时,我收到错误:

h-3.2# make
make all-recursive
Making all in .
make[2]: Nothing to be done for `all-am’.
Making all in src
protoc -I. –cpp_out=. google/protobuf/unittest.proto google/protobuf/unittest_empty.proto google/protobuf/unittest_import.proto google/protobuf/unittest_mset.proto google/protobuf/unittest_optimize_for.proto google/protobuf/unittest_embed_optimize_for.proto google/protobuf/unittest_custom_options.proto google/protobuf/unittest_lite.proto google/protobuf/unittest_import_lite.proto google/protobuf/unittest_lite_imports_nonlite.proto google/protobuf/unittest_no_generic_services.proto google/protobuf/compiler/cpp/cpp_test_bad_identifiers.proto
google/protobuf/unittest.proto:490:46: Expected number.
google/protobuf/unittest.proto:491:51: Expected number.
google/protobuf/unittest.proto:492:46: Expected number.
google/protobuf/unittest.proto:493:44: Expected number.
google/protobuf/unittest.proto:494:49: Expected number.
google/protobuf/unittest.proto:495:44: Expected number.
make[2]: *** [unittest_proto_middleman] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

我曾使用 protobuf 处理旧项目,但它是在 xcode 3.x 中创建的。 有没有办法或一些教程如何在 xcode 4.2 和 armv7 架构中使用它? 我浪费了 2 天的项目时间来研究问题,但仍然没有成功......我的项目截止日期很快,没有这个 protobuf 我就没有机会继续......

最佳答案

您是否尝试过使用 Objective-C protocol buffers

关于iphone - iOS 5、Xcode 4.2 和 ProtoBuf,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9243974/

相关文章:

iphone - 单击任何UIImage并在Objective-C中打开UIImageView

iphone - UITabBarController 的横向方向?

ios - 如何在 SceneKit Editor 中使用 Action

ios - 在 iOS 中解析连续的 JSON 流

ios - 如何更改 Flutter 中的 ios 模拟器?

ios - 无法从 Xcode 崩溃日志确定崩溃原因

iphone - JSONKit 工具上的错误

iPhone:同步两个不同图层上的动画

ios - Xcode 选项卡式应用程序 - 添加新选项卡 View

ios - 当我希望一个对象与 if 语句一起出现时,当我满足其要求时,它不起作用。 swift 、ARKit