openwrt添加本地包或者镜像地址,加速编译

openwrt在初始编译或修改设置后

如果网络环境不好

很大一部分时间都消耗在下载package的代码包上

openwrt首先会判断dl目录中是否存在需要下载的包

如果没有便去网络上下载

方法1

把dl目录链接到预先下载好包的目录

方法2

通过menuconfig设置dl目录

路径设置为绝对路径

make menuconfig

=> [*] Advanced configuration options (for developers)  —>

(/home/openwrt/dl) Download folder

方法3

通过menuconfig设置localmirror

make menuconfig

=> [*] Advanced configuration options (for developers)  —>

(https://some.faster.mirror.com/sources)    Local mirror for source packages

方法4

直接修改scripts/download.pl脚本,添加mirror

找到脚本以下位置添加其他较快的下载点

#push @mirrors, ‘http://mirror1.openwrt.org’;
push @mirrors, ‘http://mirror2.openwrt.org/sources’;
push @mirrors, ‘http://downloads.openwrt.org/sources’;

unshift @mirrors, ‘https://some.faster.mirror.com/sources’;
————————————————
原文链接:https://blog.csdn.net/zahuopuboss/java/article/details/53694694



发表评论

您的电子邮箱地址不会被公开。

57 − = 51