]> git.proxmox.com Git - mirror_frr.git/blob - doc/Building_FRR_on_OmniOS.md
Merge pull request #1329 from opensourcerouting/debian9-pkg
[mirror_frr.git] / doc / Building_FRR_on_OmniOS.md
1 Building FRR on OmniOS (OpenSolaris) from Git Source
2 ====================================================
3
4 OmniOS restrictions:
5 --------------------
6
7 - MPLS is not supported on `OmniOS` or `Solaris`. MPLS requires a Linux
8 Kernel (4.5 or higher). LDP can be built, but may have limited use
9 without MPLS
10
11 ### Enable IP & IPv6 forwarding
12
13 routeadm -e ipv4-forwarding
14 routeadm -e ipv6-forwarding
15
16 Install required packages
17 -------------------------
18
19 Add packages:
20
21 pkg install \
22 developer/build/autoconf \
23 developer/build/automake \
24 developer/lexer/flex \
25 developer/parser/bison \
26 developer/object-file \
27 developer/linker \
28 developer/library/lint \
29 developer/build/gnu-make \
30 developer/gcc51 \
31 library/idnkit \
32 library/idnkit/header-idnkit \
33 system/header \
34 system/library/math/header-math \
35 git libtool gawk pkg-config
36
37 Add additional Solaris packages:
38
39 pkgadd -d http://get.opencsw.org/now
40 /opt/csw/bin/pkgutil -U
41 /opt/csw/bin/pkgutil -y -i texinfo
42 /opt/csw/bin/pkgutil -y -i perl
43 /opt/csw/bin/pkgutil -y -i libjson_c_dev
44 /opt/csw/bin/pkgutil -y -i python27 py_pip python27_dev
45
46 Add libjson to Solaris equivalent of ld.so.conf
47
48 crle -l /opt/csw/lib -u
49
50 Add Perl packages:
51
52 cpan
53 cpan[1]> install XML::LibXML
54 cpan[2]> exit
55
56 Add pytest:
57
58 pip install pytest
59
60 Select Python 2.7 as default (required for pytest)
61
62 rm -f /usr/bin/python
63 ln -s /opt/csw/bin/python2.7 /usr/bin/python
64
65 Fix PATH for all users and non-interactive sessions. Edit `/etc/default/login`
66 and add the following default PATH:
67
68 PATH=/usr/gnu/bin:/usr/bin:/usr/sbin:/sbin:/opt/csw/bin
69
70 Edit `~/.profile` and add the following default PATH:
71
72 PATH=/usr/gnu/bin:/usr/bin:/usr/sbin:/sbin:/opt/csw/bin
73
74 Get FRR, compile it and install it (from Git)
75 ---------------------------------------------
76
77 **This assumes you want to build and install FRR from source and not using
78 any packages**
79
80 ### Add frr group and user
81
82 sudo groupadd -g 93 frr
83 sudo groupadd -g 94 frrvty
84 sudo useradd -g 93 -u 93 -G frrvty -c "FRR suite" \
85 -d /nonexistent -s /bin/false frr
86
87 (You may prefer different options on configure statement. These are just
88 an example)
89
90 git clone https://github.com/frrouting/frr.git frr
91 cd frr
92 git checkout stable/3.0
93 ./bootstrap.sh
94 export MAKE=gmake
95 export LDFLAGS="-L/opt/csw/lib"
96 export CPPFLAGS="-I/opt/csw/include"
97 export PKG_CONFIG_PATH=/opt/csw/lib/pkgconfig
98 ./configure \
99 --sysconfdir=/etc/frr \
100 --enable-exampledir=/usr/share/doc/frr/examples/ \
101 --localstatedir=/var/run/frr \
102 --sbindir=/usr/lib/frr \
103 --enable-vtysh \
104 --enable-watchfrr \
105 --enable-ospfclient=yes \
106 --enable-ospfapi=yes \
107 --enable-multipath=64 \
108 --enable-user=frr \
109 --enable-group=frr \
110 --enable-vty-group=frrvty \
111 --enable-configfile-mask=0640 \
112 --enable-logfile-mask=0640 \
113 --enable-rtadv \
114 --enable-fpm \
115 --with-pkg-git-version \
116 --with-pkg-extra-version=-MyOwnFRRVersion
117 gmake
118 gmake check
119 sudo gmake install
120
121 ### Enable IP & IPv6 forwarding
122
123 routeadm -e ipv4-forwarding
124 routeadm -e ipv6-forwarding