1. 下载openwrt源代码
-
git clone
-
enzo@t430s:~/openwrt/openwrt$ git branch -a
-
* master
-
remotes/origin/head -> origin/master
-
remotes/origin/lede-17.01
-
remotes/origin/master
-
remotes/origin/openwrt-18.06
-
enzo@t430s:~/openwrt/openwrt$ git tag
-
reboot
-
v17.01.0
-
v17.01.0-rc1
-
v17.01.0-rc2
-
v17.01.1
-
v17.01.2
-
v17.01.3
-
v17.01.4
-
v17.01.5
-
v17.01.6
-
v18.06.0
-
v18.06.0-rc1
-
v18.06.0-rc2
-
v18.06.1
-
v18.06.2
切换稳定分支
-
git checkout v18.06.2 -b v18.06.2
2.安装依赖库
sudo apt-get install libncurses5-dev zlib1g-dev gawk flex patch unzip python2.7
3. 解决编译问题
checking 'case-sensitive-fs'... failed.
解决方法:
fsutil.exe file setcasesensitiveinfo d:\work enable
关闭openwrt大小写敏感检查
/openwrt$ vi include/prereq-build.mk
-
20 #$(eval $(call testhostcommand,case-sensitive-fs, \
-
21 # openwrt can only be built on a case-sensitive filesystem, \
-
22 # rm -f $(tmp_dir)/test.*; touch $(tmp_dir)/test.fs; \
-
23 # test ! -f $(tmp_dir)/test.fs))
-
24
-
//启用ntfs区分大小写功能
-
fsutil.exe file setcasesensitiveinfo c:文件夹名称 enable
-
//禁用ntfs区分大小写功能
-
fsutil.exe file setcasesensitiveinfo c:文件夹名称 disable
./scripts/feeds update -a
./scripts/feeds install -a
4
make menuconfig
"target system" as (ti omap3/4/am33xx),
"target profile" as (ti am335x beaglebone black),
5.编译
proxychains make -j4
6. 烧写
烧写镜像到sd卡
zcat openwrt-omap-am335x-boneblack-ext4-sdcard.img.gz | sudo dd of=/dev/sdb bs=4096 conv=fsync
备注: 配置终端代理
安装proxychains终端代理,前提需要安装shadowsockets
-
vi /etc/proxychains4.conf
-
socks5 127.0.0.1 1080
参考链接:
阅读(7816) | 评论(0) | 转发(0) |