5 %define with_opaque_lsa
1
6 %define with_tcp_zebra
0
10 %define with_multipath
32
11 %define _sysconfdir
/etc
/zebra
13 Summary: Routing daemon
18 Group: System Environment
/Daemons
19 Source0: ftp
://ftp.zebra.org
/pub
/zebra
/%{name}-%{version}.tar.gz
27 Source9: zebra.logrotate
28 Source10: zebra.mpls
-docs.tar.gz
29 Patch0: zebra
-bgpd
-hash.patch
30 Patch1: zebra
-ptp.patch
31 Patch2: zebra
-linkstate.patch
32 Patch3: zebra
-ospfd
-ptmp.patch
33 Patch4: zebra
-ospfd
-misc.patch
34 Patch5: zebra
-ospfd
-olsa.patch
35 Patch7: zebra
-vtysh
-write
-config.patch
36 Patch8: zebra
-ospfd
-md5auth
-seqnum.patch
37 Patch9: zebra
-ospfd
-oi_write_q.patch
38 Patch10: zebra
-ripv1
-netmask.patch
39 Patch11: zebra
-ospfd
-md5
-buffer
-fix.patch
40 Patch12: zebra
-multi.patch
41 URL: http
://www.zebra.org
/
43 BuildRequires
: ucd
-snmp
-devel
46 BuildRequires
: texinfo tetex autoconf readline
-devel ncurses
-devel openssl
-devel pam
-devel
47 # Initscripts > 5.60 is required for IPv6 support
48 Prereq
: openssl ncurses readline initscripts pam
49 Prereq
: /sbin
/install-info
50 Provides: routingdaemon
51 BuildRoot: %{_tmppath}/%{name}-%{version}-root
52 Obsoletes
: bird gated mrt
55 GNU Zebra is a free software that manages TCP
/IP based routing
56 protocol. It takes multi
-server and multi
-thread approach to resolve
57 the current complexity of the Internet.
59 GNU Zebra supports BGP4
, BGP4
+, OSPFv2
, OSPFv3
, RIPv1
, RIPv2
, and RIPng.
61 GNU Zebra is intended to be used as a Route Server and a Route
62 Reflector. It is not a toolkit
, it provides full routing power under
63 a new architecture. GNU Zebra is unique
in design
in that it has a
64 process
for each protocol.
68 %patch0 -p1
-b .bgphash
70 %patch2 -p1
-b .linkstate
71 %patch3 -p1
-b .ospf
-ptmp
72 %patch4 -p1
-b .ospf
-misc
73 %patch5 -p1
-b .ospf
-olsa
74 %patch7 -p1
-b .vtysh
-write
75 %patch8 -p2
-b .ospf
-md5auth
-seqnum
76 %patch9 -p0
-b .ospfd
-oi_write_q
77 %patch10 -p0
-b .ripd
-netmask
78 %patch11 -p0
-b .ospfd
-md5
-buffer
79 %patch12 -p0
-b .zebra
-multi
80 %{__tar} -zxf %{SOURCE10}
93 --enable-multipath
=%with_multipath \
102 --enable-opaque
-lsa \
115 make %{?_smp_mflags} rebuild
118 make %{?_smp_mflags} MAKEINFO
="makeinfo
--no
-split"
125 rm -rf $RPM_BUILD_ROOT
127 install -d $RPM_BUILD_ROOT
/etc
/{rc.d
/init.d
,sysconfig
,logrotate.d
,pam.d
} \
128 $RPM_BUILD_ROOT
/var
/log
/zebra $RPM_BUILD_ROOT
%{_infodir}
131 DESTDIR
=$RPM_BUILD_ROOT
133 install %{SOURCE1} $RPM_BUILD_ROOT
/etc
/rc.d
/init.d
/zebra
134 install %{SOURCE2} $RPM_BUILD_ROOT
/etc
/rc.d
/init.d
/bgpd
135 install %{SOURCE3} $RPM_BUILD_ROOT
/etc
/rc.d
/init.d
/ospf6d
136 install %{SOURCE4} $RPM_BUILD_ROOT
/etc
/rc.d
/init.d
/ospfd
137 install %{SOURCE5} $RPM_BUILD_ROOT
/etc
/rc.d
/init.d
/ripd
138 install %{SOURCE6} $RPM_BUILD_ROOT
/etc
/rc.d
/init.d
/ripngd
139 install -m644
%{SOURCE8} $RPM_BUILD_ROOT
/etc
/pam.d
/zebra
140 install -m644
%{SOURCE9} $RPM_BUILD_ROOT
/etc
/logrotate.d
/zebra
144 # zebra_spec_add_service <sercice name> <port/proto> <comment>
145 # e.g. zebra_spec_add_service zebrasrv 2600/tcp "zebra service"
147 zebra_spec_add_service
()
149 # Add port /etc/services entry if it isn't already there
150 if [ -f
/etc
/services
] && ! grep
-q "^$
1[^a
-zA
-Z0
-9]"
/etc
/services
; then
151 echo "$
1 $
2 # $3" >> /etc/services
155 zebra_spec_add_service zebrasrv
2600/tcp "zebra service"
156 zebra_spec_add_service zebra
2601/tcp "zebra vty"
157 zebra_spec_add_service ripd
2602/tcp "RIPd vty"
158 zebra_spec_add_service ripngd
2603/tcp "RIPngd vty"
159 zebra_spec_add_service ospfd
2604/tcp "OSPFd vty"
160 zebra_spec_add_service bgpd
2605/tcp "BGPd vty"
161 zebra_spec_add_service ospf6d
2606/tcp "OSPF6d vty"
163 /sbin
/chkconfig
--add zebra
164 /sbin
/chkconfig
--add ripd
165 /sbin
/chkconfig
--add ripngd
166 /sbin
/chkconfig
--add ospfd
167 /sbin
/chkconfig
--add ospf6d
168 /sbin
/chkconfig
--add bgpd
170 /sbin
/install-info
%{_infodir}/zebra.info.gz %{_infodir}/dir
172 # Create dummy files if they don't exist so basic functions can be used.
173 if [ ! -e
%{_sysconfdir}/zebra.conf
]; then
174 echo "hostname `hostname`"
> %{_sysconfdir}/zebra.conf
175 chmod
640 %{_sysconfdir}/zebra.conf
177 if [ ! -e
%{_sysconfdir}/vtysh.conf
]; then
178 touch
%{_sysconfdir}/vtysh.conf
179 chmod
640 %{_sysconfdir}/vtysh.conf
183 if [ "$
1"
-ge "
1"
]; then
184 /etc
/rc.d
/init.d
/zebra condrestart
>/dev
/null
2>&1
185 /etc
/rc.d
/init.d
/ripd condrestart
>/dev
/null
2>&1
186 /etc
/rc.d
/init.d
/ripngd condrestart
>/dev
/null
2>&1
187 /etc
/rc.d
/init.d
/ospfd condrestart
>/dev
/null
2>&1
188 /etc
/rc.d
/init.d
/ospf6d condrestart
>/dev
/null
2>&1
189 /etc
/rc.d
/init.d
/bgpd condrestart
>/dev
/null
2>&1
191 /sbin
/install-info
--delete
%{_infodir}/zebra.info.gz %{_infodir}/dir
194 if [ "$
1"
= "
0"
]; then
195 /sbin
/chkconfig
--del zebra
196 /sbin
/chkconfig
--del ripd
197 /sbin
/chkconfig
--del ripngd
198 /sbin
/chkconfig
--del ospfd
199 /sbin
/chkconfig
--del ospf6d
200 /sbin
/chkconfig
--del bgpd
204 #rm -rf $RPM_BUILD_ROOT
207 %defattr(-,root
,root
)
208 %doc */*.sample
* doc
/zebra.html tools AUTHORS COPYING
209 %doc ChangeLog INSTALL NEWS README REPORTING
-BUGS SERVICES TODO
210 %dir %attr(750,root
,root
) %{_sysconfdir}
211 %dir %attr(750,root
,root
) /var
/log
/zebra
212 %dir %attr(755,root
,root
) /usr
/share
/info
218 %config /etc
/rc.d
/init.d
/*
219 %config(noreplace
) /etc
/pam.d
/zebra
220 %config(noreplace
) %attr(640,root
,root
) /etc
/logrotate.d
/*
223 * Mon Nov
11 2002 Paul Jakma
<paulj@alphyra.ie
>
224 - update to latest CVS
225 - add Greg Troxel's md5 buffer copy
/dup fix
227 - add Frank's multicast flag fix
229 * Wed Oct
09 2002 Paul Jakma
<paulj@alphyra.ie
>
230 - update to latest CVS
231 - timestamped crypt_seqnum patch
234 * Mon Sep
30 2002 Paul Jakma
<paulj@alphyra.ie
>
235 - update to latest CVS
236 - add vtysh 'write
-config
(integrated|daemon
)' patch
237 - always '
make rebuild'
in vtysh
/ to catch new commands
239 * Fri Sep
13 2002 Paul Jakma
<paulj@alphyra.ie
>
242 * Wed Sep
11 2002 Paul Jakma
<paulj@alphyra.ie
>
243 - update to latest CVS
244 - add "
/sbin
/ip route flush proto zebra" to zebra RH init on startup
246 * Sat Aug
24 2002 Paul Jakma
<paulj@alphyra.ie
>
247 - update to current CVS
248 - add OSPF point to multipoint patch
250 - add BGP
hash optimisation patch
252 * Fri Jun
14 2002 Paul Jakma
<paulj@alphyra.ie
>
253 - update to
0.93-pre1
/ CVS
254 - add link state detection support
255 - add generic PtP and RFC3021 support
258 * Thu Aug
09 2001 Elliot Lee
<sopwith@redhat.com
> 0.91a
-6
261 * Wed Aug
1 2001 Trond Eivind Glomsrød
<teg@redhat.com
> 0.91a
-5
262 - Use generic initscript strings instead of initscript specific
263 ( "Starting foo
: "
-> "Starting $prog
:"
)
265 * Fri Jul
27 2001 Elliot Lee
<sopwith@redhat.com
> 0.91a
-4
266 - Bump the release when rebuilding into the dist.
268 * Tue Feb
6 2001 Tim Powers
<timp@redhat.com
>
269 - built
for Powertools
271 * Sun Feb
4 2001 Pekka Savola
<pekkas@netcore.
fi>
272 - Hacked up from PLD Linux
0.90-1, Mandrake
0.90-1mdk and one from zebra.org.
274 - Very heavy modifications to init.d
/*, .spec
, pam
, i18n
, logrotate
, etc.
275 - Should be quite Red Hat'isque now.