openwrt-build

說明openwrt如何取得來/建立/產生imag
OpenWRT即為Open Wireless Router的build code Framework


更新記錄

item note
20160114 第一版

目錄


OpenWRT

source code 來源

Stable Release Data
Chaos Calmer 15.05 2015 September
Barrier Breaker 14.07 2014 October

資料來源 OpenWrt Version History

build system">build system

openwrt build system 包含了Makefile及patch ,讓使用者基於cross copmile方便建立toolchain及root filesystem

  • toolchain is the set of tools used to compile code for your system

    • gcc
    • binary utils like assembler and linker (binutils)
    • C Standard library (uClibc)
  • 以在PC(X86)產生TI ARM 板子toolchain而言

    • 由toolchan source在x86上面跑,產生x86 arm-gcc (此為corss-compile toolchain,用來compile ti arm板子上面的程式)

如何build openwrt

參考來源:OpenWrt 建置 – 使用方法

  • 先下載git
1
git clone git://git.openwrt.org/15.05/openwrt.git
  • 更新內部的package
1
2
3
cd openwrt  
./scripts/feeds update -a #此時會參考預計的更新檔feeds.conf.deafult
./scripts/feeds install -a
  • make
1
2
make menuconfig
make -j 3

記錄如下

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
make[3] -C package/libs/ncurses host-compile
make[3] -C package/libs/toolchain compile
make[3] -C package/system/opkg host-compile
make[3] -C package/system/usign host-compile
make[3] -C package/boot/uboot-ar71xx compile
make[3] -C package/kernel/gpio-button-hotplug compile
make[3] -C package/firmware/linux-firmware compile
make[3] -C package/libs/ocf-crypto-headers compile
make[3] -C package/network/services/dropbear compile
make[3] -C package/libs/libpcap compile
make[3] -C package/network/utils/linux-atm compile
make[3] -C package/network/utils/resolveip compile
make[3] -C package/utils/busybox compile
make[3] -C package/libs/libnl-tiny compile
make[3] -C package/libs/libjson-c compile
make[3] -C package/utils/lua compile
make[3] -C package/libs/lzo compile
make[3] -C package/libs/zlib compile
make[3] -C package/libs/ncurses compile
make[3] -C package/kernel/linux compile
make[3] -C package/libs/openssl compile
make[3] -C package/network/utils/iw compile
make[3] -C package/network/utils/iptables compile
make[3] -C package/network/ipv6/odhcp6c compile
make[3] -C package/network/services/dnsmasq compile
make[3] -C package/network/services/ppp compile
make[3] -C package/libs/libubox compile
make[3] -C package/utils/util-linux compile
make[3] -C package/system/ubus compile
make[3] -C package/system/uci compile
make[3] -C package/utils/jsonfilter compile
make[3] -C package/system/usign compile
make[3] -C package/network/config/firewall compile
make[3] -C package/network/config/swconfig compile
make[3] -C package/network/services/odhcpd compile
make[3] -C package/network/utils/iwinfo compile
make[3] -C package/system/mtd compile
make[3] -C package/system/opkg compile
make[3] -C package/network/config/netifd compile
make[3] -C package/system/ubox compile
make[3] -C package/network/services/hostapd compile
make[3] -C package/system/fstools compile
make[3] -C package/boot/uboot-envtools compile
make[3] -C package/kernel/mac80211 compile
make[3] -C package/utils/ubi-utils compile
make[3] -C package/system/procd compile
make[3] -C package/base-files compile
make[2] package/install
make[3] package/preconfig
make[2] target/install
make[3] -C target/linux install
make[2] package/index

其它說明

  • feeds.conf.deafult
1
2
3
4
5
6
$ cat feeds.conf.default
src-git packages https://github.com/openwrt/packages.git;for-15.05
src-git luci https://github.com/openwrt/luci.git;for-15.05
src-git routing https://github.com/openwrt-routing/packages.git;for-15.05
src-git telephony https://github.com/openwrt/telephony.git;for-15.05
src-git management https://github.com/openwrt-management/packages.git;for-15.05

參考來源