编译wndr4300 openwrt 15.05固件
2015 年 12 月 11 日 编译wndr4300 openwrt 15.05固件有10条评论
为wndr4300编译openwrt 15.05系统,内容如下:
操作环境
ubuntu 14.04 64位
1. 安装依赖包
sudo apt-get install subversion build-essential libncurses5-dev zlib1g-dev gawk git ccache gettext libssl-dev xsltproc
2. 下载源码
cd
git clone git://git.openwrt.org/15.05/openwrt.git
cd openwrt
git checkout 15.05
./scripts/feeds update -a
./scripts/feeds install luci
git clone git://git.openwrt.org/15.05/openwrt.git
cd openwrt
git checkout 15.05
./scripts/feeds update -a
./scripts/feeds install luci
3. 编译
获取官方配置
wget https://downloads.openwrt.org/chaos_calmer/15.05/ar71xx/nand/config.diff
将 config.diffg 文件
CONFIG_TARGET_ar71xx_nand_R6100=y
行修改为
CONFIG_TARGET_ar71xx_nand_WNDR4300=y
生成配置
cat config.diff >> .config
make defconfig
make defconfig
修改 /root 为128MB
修改 target/linux/ar71xx/image/Makefile 文件, 修改 wndr4300_mtdlayout 中 23552k(ubi) 为 120832k(ubi), 25600k@0x6c0000(firmware) 为 122880k@0x6c0000(firmware)
修改 ./package/network/config/firewall/files/firewall.config,将 wan 中 option input REJECT 改为 option input ACCEPT,这样就可以在刷机后从外部(上一层路由)访问路由,而不需要接入到路由下。
运行编译
make
或使用 make -jN 加速编译,如 make -j4。
4. 生成文件位置
最后文件生成在 bin 目录下:
openwrt/bin/ar71xx/openwrt-15.05-ar71xx-nand-wndr4300-squashfs-sysupgrade.tar
openwrt/bin/ar71xx/openwrt-15.05-ar71xx-nand-wndr4300-ubi-factory.img
另外 编译 openwrt 14.07 固件参考
评论:10