golang_protobuf环境搭建
2024-10-15 02:35:03
搭建golang使用rotobuf使用环境
一 安装protobuf:
1 下载protobuf源码:https://github.com/google/protobuf
2 进入源码目录: ./autogen.sh
可能遇到问题:1 该脚本会下载gmock,
若被墙,则需FQ下载并解压为gmock放在该源码目录下
2 脚本会执行autoreconf命令,若未安装此命令则手动安装(ubantu安装:sudo apt-get install autoconf automake libtool )
3 ./configure;make;make check; sudo make install
4 sudo ldconfig # refresh shared library cache
二 安装gogoprotobuf:
1 go get -u github.com/golang/protobuf
三 使用gogoprotobuf:
1 protoc --go_out=. myproto.proto
示例地址:https://godoc.org/github.com/golang/protobuf/proto
最新文章
- Angular杂谈系列1-如何在Angular2中使用jQuery及其插件
- js正则表达式校验正数、负数、和小数:^(\-|\+)?\d+(\.\d+)?$
- 从linux0.11中起动部分代码看汇编调用c语言函数
- PHP实现实现数字补零格式化
- Android之UI编程(一):线性布局
- Node.js Express 框架 GET方法
- OC 内存泄露 自动释放池
- 【C#】ContextMenuStrip 右键菜单颜色设置
- 查看CPU是否支持虚拟化
- Hibernate 性能优化之二级缓存
- 如何关闭android studio开发环境自动保存
- s:if 判断 s:property
- centosFTP服务搭建及权限配置
- MongoDB - Indexes
- ApplicationContext(七)Message 源
- c++11 随机代码记录
- Oracle EBS 获取说明性弹性域全局数据元
- ZT linux的mount(挂载)命令详解
- 连接oracle服务器超慢--原因分析
- cmd命令提示符大全(干货)
热门文章
- PL/SQL:使用pragma restrict_references限制包权限
- div 水平居中
- [D3] 5 .rangeBands
- java 使用线程做一个简单的ATM存取款实例.(转)
- /bin/bash^M: bad interpreter: 没有那个文件或目录--转载
- SharePoint Dialog 使用
- PHP能得到你是从什么页面过来的,r…
- jquery自调用匿名函数解析
- Bootstrap--全局css样式之表单
- Http协议、线程、线程池