百度区块链 XuperChain开发教程(环境准备)

 

一、 XuperChain简介

百度区块链 XuperChain 的官网地址: https://xchain.baidu.com/

引用官方数据:

截至:2019-07-07 已经有用户:3,322,805人 ,突破:330万用户。

XuperUion是超级链体系下的第一个开源项目,是构建超级联盟网络的底层方案。

GitHub 地址:https://github.com/xuperchain/xuperunion

 

二、安装参考文档( 多节点网络搭建 ) :

参考文档: https://github.com/xuperchain/xuperunion/wiki/3.-Getting-Started

Golang版本: go1.12.5.linux-amd64.tar.gz

查看XuperChain版本:

下载XuperUnion代码:

git clone https://github.com/xuperchain/xuperunion

 

 git branch -a
* master
  remotes/origin/HEAD -> origin/master
  remotes/origin/master
  remotes/origin/v3.1
  remotes/origin/v3.2

git checkout -b origin/v3.2
Switched to a new branch 'origin/v3.2'

 git branch
  master
* origin/v3.2

显示已经切换到最新分支。

进入: XuperUnion 目录,执行make 命令:

可以看到如下消息:

buildpkg xchain-cli github.com/xuperchain/xuperunion/cmd/cli

go build -o xchain-cli -ldflags '-X main.buildVersion=heads/origin/v3.2 -X main.buildDate=2019-07-07-22:15:06 -X main.commitHash=09d8dd0' github.com/xuperchain/xuperunion/cmd/cli

buildpkg xchain github.com/xuperchain/xuperunion/cmd/xchain

go build -o xchain -ldflags '-X main.buildVersion=heads/origin/v3.2 -X main.buildDate=2019-07-07-22:15:41 -X main.commitHash=09d8dd0' github.com/xuperchain/xuperunion/cmd/xchain

+ mkdir -p plugins/kv plugins/crypto plugins/consensus plugins/contract
+ go build --buildmode=plugin --tags multi -o plugins/kv/kv-ldb-multi.so.1.0.0 github.com/xuperchain/xuperunion/kv/kvdb/plugin-ldb
+ go build --buildmode=plugin --tags single -o plugins/kv/kv-ldb-single.so.1.0.0 github.com/xuperchain/xuperunion/kv/kvdb/plugin-ldb
+ go build --buildmode=plugin -o plugins/kv/kv-badger.so.1.0.0 github.com/xuperchain/xuperunion/kv/kvdb/plugin-badger
+ go build --buildmode=plugin -o plugins/crypto/crypto-default.so.1.0.0 github.com/xuperchain/xuperunion/crypto/client/xchain
+ go build --buildmode=plugin -o plugins/consensus/consensus-pow.so.1.0.0 github.com/xuperchain/xuperunion/consensus/pow
+ go build --buildmode=plugin -o plugins/consensus/consensus-single.so.1.0.0 github.com/xuperchain/xuperunion/consensus/single
+ go build --buildmode=plugin -o plugins/consensus/consensus-tdpos.so.1.0.0 github.com/xuperchain/xuperunion/consensus/tdpos/main\

 

上面可以看到以插件方式编译的模块: kv数据库, pow,single,tdpos等插件。

 

下一篇进行网络搭建。

 

©️2020 CSDN 皮肤主题: 编程工作室 设计师:CSDN官方博客 返回首页