Ubuntu版本 20.04
1、下载 && 安装依赖
Github链接:
GitHub – p4lang/behavioral-model: The reference P4 software switch
可以自己手动下载依赖,如下是bmv2的一些依赖项
# sudo apt-get install -y automake cmake libgmp-dev \
libpcap-dev libboost-dev libboost-test-dev libboost-program-options-dev \
libboost-system-dev libboost-filesystem-dev libboost-thread-dev \
libevent-dev libtool flex bison pkg-config g++ libssl-dev
也可以直接通过README中给出的脚本直接运行 ./install_deps.sh
# git clone https://github.com/p4lang/behavioral-model.git
# cd behavioral-model
# ./install_deps.sh
这里就是 ./install_deps.sh 脚本里的具体的内容(建议直接用脚本执行,简单多了。。)
安装依赖项这里也说了还要装 thrift 和 nanomsg 啥的,但是在上面的脚本里好像都写了,因此也不需要另外再单独安装了(如果不放心或者后面发现不行可以回来再手动安装着两个东西)
2、Building Code
# ./autogen.sh
# ./configure
# make
# [sudo] make install # if you need to install bmv2
版权声明:本文为weixin_44260459原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。