ubuntu--DPDK环境适配

2021/10/17 7:10:00

本文主要是介绍ubuntu--DPDK环境适配,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

参考链接

ubuntu镜像-ubuntu下载地址-ubuntu安装教程-阿里巴巴开源镜像站
https://www.cnblogs.com/hx1998/p/10886737.html
https://blog.csdn.net/wangyongh/article/details/105180407 

1. 升级python2到python3
1.1安装python3有许多的依赖库,由于不知道自己电脑缺哪些库,全部下载。
sudo apt-get update
sudo apt-get upgrade
sudo apt-get upgrade --fix-missing
sudo apt-get dist-upgrade
sudo apt-get update
sudo apt-get upgrade

sudo apt-get install zlib1g
sudo apt-get install zlib1g.dev
sudo apt-get install zlib-devel
sudo apt-get install bzip2-devel
sudo apt-get install build-essential
sudo apt-get install python-dev
sudo apt-get install python-setuptools
sudo apt-get install python-setuptools
sudo apt-get install python-pip
sudo apt-get install python-smbus
sudo apt-get install libncursesw5-dev
sudo apt-get install libgdbm-dev
sudo apt-get install libc6-dev
sudo apt-get install zlib1g-dev
sudo apt-get install libsqlite3-dev
sudo apt-get install tk-dev
sudo apt-get install libssl-dev
sudo apt-get install openssl
sudo apt-get install libffi-dev
sudo apt-get install gcc -y

1.2. 开始安装python3

cd /usr/local
wget https://www.python.org/ftp/python/3.6.5/Python-3.6.5.tgz
sudo wget https://www.python.org/ftp/python/3.6.5/Python-3.6.5.tgz
tar -xvf Python-3.6.5.tgz
sudo tar -xvf Python-3.6.5.tgz
cd ./Python-3.6.5/
./configure --prefix=/usr/local/python3
sudo ./configure --prefix=/usr/local/python3
sudo make
sudo make install 

sudo rm -rf  /usr/bin/python3 
sudo ln -s /usr/local/python3/bin/python3  /usr/bin/python3

看看是否一致
python -V
/usr/bin/python3 -V

1.3 安装pip3
sudo wget --no-check-certificate  https://pypi.python.org/packages/source/s/setuptools/setuptools-19.6.tar.gz#md5=c607dd118eae682c44ed146367a17e26
sudo tar -zxvf setuptools-19.6.tar.gz
cd setuptools-19.6/
sudo python3 -V
sudo python3 setup.py build
sudo ln -s /usr/local/python3/bin/pip3 /usr/bin/pip3
sudo pip3 install --upgrade pip
sudo pip3 install --upgrade pip -vvv
sudo pip3 install --upgrade setuptools

1.4 尝试用pip3下载东西
sudo  python3 -m pip install paramiko
sudo pip3 install meson ninja
 



这篇关于ubuntu--DPDK环境适配的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!


扫一扫关注最新编程教程