安装composer
wget http://curl.haxx.se/ca/cacert.pem
curl -sS https://getcomposer.org/installer | php -- --cafile=cacert.pem
安装protoc-gen-php
composer require "protocolbuffers/protoc-gen-php:dev-master"
如果网络差可以使用代理(* 转 http 代理)
proxychains4 composer require "protocolbuffers/protoc-gen-php:dev-master"