%{!?with_irdp: %global with_irdp 1 }
%{!?with_rtadv: %global with_rtadv 1 }
%{!?with_ldpd: %global with_ldpd 1 }
+%{!?with_nhrpd: %global with_nhrpd 1 }
+%{!?with_eigrpd: %global with_eigrpd 1 }
+%{!?with_babeld: %global with_babeld 1 }
%{!?with_shared: %global with_shared 1 }
%{!?with_multipath: %global with_multipath 256 }
%{!?frr_user: %global frr_user frr }
%{expand: %%global rpmversion %(echo '@VERSION@' | tr [:blank:]- _ )}
%define frrversion @VERSION@
- #### Check version of texi2html
- # Old versions don't support "--number-footnotes" option.
- %{expand: %%global texi2htmlversion %(if [[ -f /usr/bin/texi2html ]]; then /usr/bin/texi2html --version | cut -d. -f1; else echo 0; fi)}
-
#### Check for systemd or init.d (upstart)
# Check for init.d (upstart) as used in CentOS 6 or systemd (ie CentOS 7)
- %{expand: %%global initsystem %(if [[ `/sbin/init --version 2> /dev/null` =~ upstart ]]; then echo upstart; elif [[ `file /sbin/init` =~ "symbolic link to \`../lib/systemd/systemd'" ]]; then echo systemd; elif [[ `systemctl` =~ -\.mount ]]; then echo systemd; fi)}
+ %if 0%{?fedora} >= 15 || 0%{?rhel} >= 7 || 0%{?suse_version} >= 1210
+ %global initsystem systemd
+ %else
+ %if (0%{?fedora} && 0%{?fedora} < 15) || (0%{?rhel} && 0%{?rhel} < 7)
+ %global initsystem upstart
+ %else
+ %{expand: %%global initsystem %(if [[ `/sbin/init --version 2> /dev/null` =~ upstart ]]; then echo upstart; elif [[ `readlink -f /sbin/init` = /usr/lib/systemd/systemd ]]; then echo systemd; elif [[ `systemctl` =~ -\.mount ]]; then echo systemd; fi)}
+ %endif
+ %endif
#
# If init system is systemd, then always disable watchfrr
#
#### Check for RedHat 6.x or CentOS 6.x - they are too old to support PIM.
#### Always disable it on these old systems unconditionally
- %{expand: %%global redhat6 %(if [[ `cat /etc/redhat-release 2> /dev/null` =~ release\ 6\. ]]; then echo 6; else echo 0; fi)}
#
- # if CentOS 6 / RedHat 6, then disable PIMd
- %if "%{redhat6}" == "6"
+ # if CentOS / RedHat and version < 7, then disable PIMd (too old, won't work)
+ %if 0%{?rhel} && 0%{?rhel} < 7
%global with_pimd 0
%endif
%define daemon_pimd ""
%endif
+%if %{with_nhrpd}
+%define daemon_nhrpd nhrpd
+%else
+%define daemon_nhrpd ""
+%endif
+
+%if %{with_eigrpd}
+%define daemon_eigrpd eigrpd
+%else
+%define daemon_eigrpd ""
+%endif
+
+%if %{with_babeld}
+%define daemon_babeld babeld
+%else
+%define daemon_babeld ""
+%endif
+
%if %{with_watchfrr}
%define daemon_watchfrr watchfrr
%else
%define daemon_watchfrr ""
%endif
-%define all_daemons %{daemon_list} %{daemon_ldpd} %{daemon_pimd} %{daemon_watchfrr}
+%define all_daemons %{daemon_list} %{daemon_ldpd} %{daemon_pimd} %{daemon_nhrpd} %{daemon_eigrpd} %{daemon_babeld} %{daemon_watchfrr}
# allow build dir to be kept
%{!?keep_build: %global keep_build 0 }
BuildRequires: gcc texi2html texinfo patch libcap-devel groff
BuildRequires: readline readline-devel ncurses ncurses-devel
BuildRequires: json-c-devel bison >= 2.7 flex make
+%if 0%{?rhel} && 0%{?rhel} < 7
+#python27-devel is available from ius community repo for RedHat/CentOS 6
+BuildRequires: python27-devel
+%else
+BuildRequires: python-devel >= 2.7
+%endif
Requires: ncurses json-c initscripts
%if %{with_pam}
BuildRequires: pam-devel
protocol. It takes multi-server and multi-thread approach to resolve
the current complexity of the Internet.
-FRRouting supports BGP4, OSPFv2, OSPFv3, ISIS, RIP, RIPng, PIM
-and LDP
+FRRouting supports BGP4, OSPFv2, OSPFv3, ISIS, RIP, RIPng, PIM, LDP
+NHRP and EIGRP.
FRRouting is a fork of Quagga.
%else
--disable-pimd \
%endif
+%if %{with_nhrpd}
+ --enable-nhrpd \
+%else
+ --disable-nhrpd \
+%endif
+%if %{with_eigrpd}
+ --enable-eigrpd \
+%else
+ --disable-eigrpd \
+%endif
+%if %{with_babeld}
+ --enable-babeld \
+%else
+ --disable-babeld \
+%endif
%if %{with_pam}
--with-libpam \
%endif
%else
--disable-bgp-vnc \
%endif
- --enable-gcc-rdynamic \
--enable-isisd=yes \
%if "%{initsystem}" == "systemd"
--enable-systemd=yes \
make %{?_smp_mflags} MAKEINFO="makeinfo --no-split"
pushd doc
- %if %{texi2htmlversion} < 5
+ if [ $(texi2html --version | cut -d. -f1) -lt 5 ]; then
texi2html --number-sections frr.texi
- %else
+ else
texi2html --number-footnotes --number-sections frr.texi
- %endif
+ fi
popd
%install
zebra_spec_add_service ospfapi 2607/tcp "OSPF-API"
%endif
zebra_spec_add_service isisd 2608/tcp "ISISd vty"
+%if %{with_babeld}
+zebra_spec_add_service babeld 2609/tcp "BABELd vty"
+%endif
+%if %{with_nhrpd}
+zebra_spec_add_service nhrpd 2610/tcp "NHRPd vty"
+%endif
%if %{with_pimd}
zebra_spec_add_service pimd 2611/tcp "PIMd vty"
%endif
%if %{with_ldpd}
zebra_spec_add_service ldpd 2612/tcp "LDPd vty"
%endif
+%if %{with_eigrpd}
+zebra_spec_add_service eigrpd 2613/tcp "EIGRPd vty"
+%endif
%if "%{initsystem}" == "systemd"
for daemon in %all_daemons ; do
%if %{with_ldpd}
%{_sbindir}/ldpd
%endif
+%if %{with_eigrpd}
+ %{_sbindir}/eigrpd
+%endif
+%if %{with_nhrpd}
+ %{_sbindir}/nhrpd
+%endif
+%if %{with_babeld}
+ %{_sbindir}/babeld
+%endif
%if %{with_shared}
%{_libdir}/lib*.so
%{_libdir}/lib*.so.0
%dir %attr(755,root,root) %{_includedir}/%{name}/ospfapi
%{_includedir}/%name/ospfapi/*.h
%endif
+%if %{with_eigrpd}
+%dir %attr(755,root,root) %{_includedir}/%{name}/eigrpd
+%{_includedir}/%name/eigrpd/*.h
+%endif
%changelog
-* Mon Apr 17 2017 Martin Winter <mwinter@opensourcerouting.org> - %{version}
+* Mon Jun 5 2017 Martin Winter <mwinter@opensourcerouting.org> - %{version}
+- added NHRP and EIGRP daemon
+
+* Mon Apr 17 2017 Martin Winter <mwinter@opensourcerouting.org>
- new subpackage frr-pythontools with python 2.7 restart script
- remove PIMd from CentOS/RedHat 6 RPM packages (won't work - too old)
- converted to single frr init script (not per daemon) based on debian init script