簡體   English   中英

iOS 5,Xcode 4.2和ProtoBuf

[英]iOS 5 , Xcode 4.2 and ProtoBuf

我試圖編譯谷歌protobuf的協議,用於在我的iOS 5的項目中使用它,但沒有成功......但我只找到一個博客文章的話題在這里 但是當我嘗試這種方法時,我收到錯誤消息:

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天的時間來研究問題,但仍然沒有成功...我的項目期限很快就要到了,沒有這個原型我就沒有機會繼續進行...

您是否嘗試過使用Objective-C協議緩沖區

這篇博客文章提供了有關如何使用armv7,armv7s,適用於iOS的i386架構編譯protobuf庫的說明。 博客文章中還有一個鏈接,用於下載可在設備以及模擬器上運行的protobuf的預編譯iOS庫。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM