1. 下载openwrt源码
openwrt开放源码URL: http://git.openwrt.org 。上面有各个openwrt的各个开发分支,选择需要的进行下载就行了。$ git clone git://git.openwrt.org/12.09/openwrt.git openwrt-12.09 $ git clone git://git.openwrt.org/12.09/packages.git packages-12.09
不知道这两个有什么关系,先都下载了。更新种子列表:$ cd openwrt-12.09 $ ./scripts/feeds update -a $ ./scripts/feeds install -a
2. openwrt源码结构
openwrt-12.09
|----feeds/
|----include/
|----package/
|----scripts/
|----target/
|----toolchain/
|----tools/
先重点来关注下package,target,toolchain,tools四个目录吧。
3. openwrt编译
- 单编package
$ make package/qos/clean $ make package/qos/compile $ make package/qos/install