在ubuntu 22.04上编译openwrt v22.03

2,278 阅读1分钟

为Ubuntu 22.04的OpenWrt master、22.03和21.02分支提供的现代化设置,不再需要python2.7。Python3默认安装在Ubuntu22.04中。

在下载代码和编译前,运行一下命令

# 更新系统以及一些依赖包
sudo apt update
sudo apt install build-essential clang flex bison g++ gawk gcc-multilib g++-multilib gettext git libncurses5-dev libssl-dev python3-distutils rsync unzip zlib1g-dev file wget
# 下载代码
git clone https://git.openwrt.org/openwrt/openwrt.git
cd openwrt
git pull
# 选择版本
git branch -a
git tag
git checkout v22.03.3
# 更新 feeds
./scripts/feeds update -a
./scripts/feeds install -a
# 如果install 有报错
# WARNING: No feed for package 'libedit' found很多库没有的话,会有问题的,请更新系统和依赖包

可以参考

openwrt.org/docs/guide-… openwrt.org/docs/guide-…