Add protobuf support
Merge remote-tracking branch 'snowcold/master'