An implementation of Protocol Buffers in Objective C.
Protocol Buffers are a way of encoding structured data in an efficient yet extensible format. This project is based on an implementation of Protocol Buffers from Google. See the Google protobuf project for more information.
In testing for Cocoa Pods. It's not been submitted to the central repo yet.
- added pre-compiled binaries for protoc and protoc-gen-obj
- added universal binary
- compiled with maverick
Add the ProtocolBuffers.framework to your project. The library will work for iOS Simulator and iOS 7.0 on iPhone 4,4s,5,5s.
To generate protocol buffers model, create a .proto file, in terminal navigate to the bin/protobuf/2.5.0/bin
directory and run protoc --objc_out=./ <your_folder_with_.protofiles>
.
- Install XCode and XCode command line tools
- Install brew
brew install autogen
brew install aclocal
brew install automake
brew install protobuf
- Download source or clone repository to local machine
cd
into root directory of project./autogen.sh
./configure
make -B -d & make install
cd /folder/with/.proto files/ && protoc --objc_out=/my/output/folder *
Issue installing Protobufs 2.5.0 in Mavericks. Comment out the iosfwd.
#ifdef __DECCXX
// HP C++'s iosfwd doesn't work.
#include <iostream>
#else
#include <sstream>
//#include <iosfwd> // comment out this for the sstream
#endif
/usr/local/bin
protoc (file or symlink)
protoc-gen-objc (file or symlink)
/usr/local/include
needs a symlink called "protobuf" to /usr/local/Cellar/protobuf/2.5.0/include
/usr/local/opt
needs a symlink called "protobuf" to /usr/local/Cellar/protobuf/2.5.0
- Jon Parise [email protected]
- Cyrus Najmabadi (http://code.google.com/p/metasyntactic/wiki/ProtocolBuffers)
- Sergey Martynov (http://github.com/martynovs/protobuf-objc)
- Kenton Varda, Sanjay Ghemawat, Jeff Dean, and others