]> git.proxmox.com Git - mirror_frr.git/blame - doc/developer/building-frr-for-openwrt.rst
Merge pull request #3899 from ton31337/fix/remove_private_as_with_local_as
[mirror_frr.git] / doc / developer / building-frr-for-openwrt.rst
CommitLineData
625b8bc2
CF
1OpenWRT
2=======
3
4Prepare build environment
5-------------------------
6
7For Debian based distributions, run:
8
9::
10
11 sudo apt-get install git build-essential libssl-dev libncurses5-dev \
7d9a2e6d 12 unzip zlib1g-dev subversion mercurial
625b8bc2
CF
13
14For other environments, instructions can be found in the
15`official documentation
16<https://wiki.openwrt.org/doc/howto/buildroot.exigence#examples_of_package_installations>`_.
17
18
19Get OpenWRT Sources (from Git)
20------------------------------
21
22.. note::
23 The OpenWRT build will fail if you run it as root. So take care to run it as a nonprivileged user.
24
25Clone the OpenWRT sources and retrieve the package feeds
26
27::
28
29 git clone https://github.com/openwrt/openwrt.git
30 cd openwrt
31 ./scripts/feeds update -a
32 ./scripts/feeds install -a
33 cd feeds/routing
34 git fetch origin pull/319/head
35 git read-tree --prefix=frr/ -u FETCH_HEAD:frr
36 cd ../../package/feeds/routing/
37 ln -sv ../../../feeds/routing/frr .
38 cd ../../..
39
40Configure OpenWRT for your target and select the needed FRR packages in Network -> Routing and Redirection -> frr,
41exit and save
42
43::
44
45 make menuconfig
46
47Then, to compile either a complete OpenWRT image, or the FRR packages, run:
48
49::
50
51 make or make package/frr/compile
52
53It may be possible that on first build ``make package/frr/compile`` not
54to work and it may be needed to run a ``make`` for the entire build
55environment. Add ``V=s`` to get more debugging output.
56
57Work with sources
58-----------------
59
60To update to a newer version, or change other options, you need to edit the ``feeds/routing/frr/Makefile``.
61
62Usage
63-----
64
65Edit ``/usr/sbin/frr.init`` and add/remove the daemons name in section
56f0bea7 66``DAEMONS=`` or don't install unneeded packages For example: zebra bgpd ldpd
625b8bc2
CF
67isisd nhrpd ospfd ospf6d pimd ripd ripngd
68
56f0bea7 69Enable the service
625b8bc2
CF
70^^^^^^^^^^^^^^^^^^
71
72- ``service frr enable``
73
74Start the service
75^^^^^^^^^^^^^^^^^
76
77- ``service frr start``