I cannot install the Protobuf 2.6.0, detail as below:
ryous-MacBook-Pro:~ raniys$ protoc --version
libprotoc 2.6.0
ryous-MacBook-Pro:~ raniys$ cd /Users/raniys/Downloads/protobuf-2.6.0
ryous-MacBook-Pro:protobuf-2.6.0 raniys$ ./autogen.sh
Google Test not present. Fetching gtest-1.5.0 from the web...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 1586 100 1586 0 0 2948 0 --:--:-- --:--:-- --:--:-- 2953
tar: Unrecognized archive format
tar: Error exit delayed from previous errors.
I need the proto2, and the 2.6.1 cannot be find by brew:
ryous-MacBook-Pro:~ raniys$ brew install protobuf261
Error: No available formula with the name "protobuf261"
==> Searching for similarly named formulae...
Error: No similarly named formulae found.
==> Searching taps...
Error: No formulae found in taps.
Please use protobuf 3.1.0 release instead. Protobuf 3.x supports both proto2 and proto3 and it's wire compatible with old 2.x versions.
The old link in protobuf-2.6.0/autogen.sh no longer works because google code site has been shutdown. You can download the latest versions here:
https://github.com/google/protobuf/releases/tag/v3.1.0
It's not a good idea. We have 3 more projects and all of them develop with protobuf 2, so it's not easy to upgrade. Anyway, I've found how to install the protobuf-2.6.1 for my Mac:
./autogen.sh
./configure
make
make install
*4. download the protobuf-objc and build(only for oc):
git clone https://github.com/alexeyxo/protobuf-objc.git
cd protobuf-objc
./scripts/build.sh
Wish can help someone, thanks!
thanks. this worked
Thanks @gaoshanyu
It worked thank you so much! @gaoshanyu
Most helpful comment
It's not a good idea. We have 3 more projects and all of them develop with protobuf 2, so it's not easy to upgrade. Anyway, I've found how to install the protobuf-2.6.1 for my Mac:
*4. download the protobuf-objc and build(only for oc):
Wish can help someone, thanks!