distro/redhat: fix rpmlint warnings

* quagga.spec.in: Use %global when defining globals inside conditional
  blocks.
  Comment Obsoletes as rpmlint wants specific versions. The packages are
  long gone, but leave as historical documentation.
  Don't use %version in changelog entries, or other live macros.
  Fix spaces-for-indent everywhere, use tab (sorry spaces people).
diff --git a/redhat/quagga.spec.in b/redhat/quagga.spec.in
index 0e2306e..0c927e6 100644
--- a/redhat/quagga.spec.in
+++ b/redhat/quagga.spec.in
@@ -15,7 +15,7 @@
 %{!?with_tcp_zebra:		%global	with_tcp_zebra		0 }
 %{!?with_vtysh:			%global	with_vtysh		1 }
 %{!?with_pam:			%global	with_pam		1 }
-%{!?with_ospfclient:		%global	with_ospfclient 	1 }
+%{!?with_ospfclient:		%global	with_ospfclient		1 }
 %{!?with_ospfapi:		%global	with_ospfapi		1 }
 %{!?with_irdp:			%global	with_irdp		1 }
 %{!?with_rtadv:			%global	with_rtadv		1 }
@@ -26,8 +26,8 @@
 %{!?with_multipath:		%global	with_multipath		64 }
 %{!?quagga_user:		%global	quagga_user		quagga }
 %{!?vty_group:			%global	vty_group		quaggavt }
-%{!?with_fpm:			%global	with_fpm 		0 }
-%{!?with_watchquagga:		%global	with_watchquagga 	1 }
+%{!?with_fpm:			%global	with_fpm		0 }
+%{!?with_watchquagga:		%global	with_watchquagga	1 }
 
 # path defines
 %define		_sysconfdir	/etc/quagga
@@ -41,8 +41,8 @@
 
 #### Version String tweak
 # Remove invalid characters form version string and replace with _
-%{expand: %%define rpmversion %(echo '@VERSION@' | tr [:blank:]- _ )}
-%define         quaggaversion   @VERSION@
+%{expand: %%global rpmversion %(echo '@VERSION@' | tr [:blank:]- _ )}
+%define		quaggaversion	@VERSION@
 
 #### Check version of texi2html 
 # Old versions don't support "--number-footnotes" option.
@@ -68,9 +68,9 @@
 %endif
 
 # misc internal defines
-%{!?quagga_uid:		%define         quagga_uid      92 }
-%{!?quagga_gid:		%define         quagga_gid      92 }
-%{!?vty_gid:		%define		vty_gid		85 }
+%{!?quagga_uid:		%global		quagga_uid	92 }
+%{!?quagga_gid:		%global		quagga_gid	92 }
+%{!?vty_gid:		%global		vty_gid		85 }
 
 %define		daemon_list	zebra ripd ospfd bgpd
 
@@ -83,19 +83,19 @@
 %endif
 
 %if %{with_pimd}
-%define         daemon_pimd	pimd
+%define		daemon_pimd	pimd
 %else
 %define		daemon_pimd	""
 %endif
 
 %if %{with_nhrpd}
-%define         daemon_nhrpd	nhrpd
+%define		daemon_nhrpd	nhrpd
 %else
 %define		daemon_nhrpd	""
 %endif
 
 %if %{with_watchquagga}
-%define         daemon_watchquagga	watchquagga
+%define		daemon_watchquagga	watchquagga
 %else
 %define		daemon_watchquagga	""
 %endif
@@ -106,7 +106,7 @@
 %{!?keep_build:		%global		keep_build	0 }
 
 #release sub-revision (the two digits after the CONFDATE)
-%{!?release_rev:	%define		release_rev	01 }
+%{!?release_rev:	%global		release_rev	01 }
 
 Summary: Routing daemon
 Name:			quagga
@@ -121,18 +121,18 @@
 Requires(preun): /sbin/install-info
 Requires(post):	/sbin/install-info
 BuildRequires:	texi2html texinfo autoconf patch libcap-devel groff
-BuildRequires:  perl-generators pkgconfig
+BuildRequires:	perl-generators pkgconfig
 %if %{with_snmp}
 BuildRequires:	net-snmp-devel
-Requires:		net-snmp
+Requires:	net-snmp
 %endif
 %if %{with_vtysh}
 BuildRequires:	readline readline-devel ncurses ncurses-devel
-Requires:		ncurses
+Requires:	ncurses
 %endif
 %if %{with_pam}
 BuildRequires:	pam-devel
-Requires:		pam
+Requires:	pam
 %endif
 %if %{with_nhrpd}
 BuildRequires:	c-ares-devel
@@ -149,7 +149,7 @@
 %endif
 Provides:			routingdaemon = %{version}-%{release}
 BuildRoot:			%{_tmppath}/%{name}-%{version}-root
-Obsoletes:			mrt zebra quagga-sysvinit
+#Obsoletes:			mrt zebra quagga-sysvinit
 
 %define __perl_requires %{zeb_rh_src}/quagga-filter-perl-requires.sh
 
@@ -175,20 +175,10 @@
 developing OSPF-API and quagga applications.
 
 %prep
-%setup  -q -n quagga-%{quaggaversion}
+%setup -q -n quagga-%{quaggaversion}
 
 %build
 
-# For standard gcc verbosity, uncomment these lines:
-#CFLAGS="%{optflags} -Wall -Wsign-compare -Wpointer-arith"
-#CFLAGS="${CFLAGS} -Wbad-function-cast -Wwrite-strings"
-
-# For ultra gcc verbosity, uncomment these lines also:
-#CFLAGS="${CFLAGS} -W -Wcast-qual -Wstrict-prototypes"
-#CFLAGS="${CFLAGS} -Wmissing-declarations -Wmissing-noreturn"
-#CFLAGS="${CFLAGS} -Wmissing-format-attribute -Wunreachable-code"
-#CFLAGS="${CFLAGS} -Wpacked -Wpadded"
-
 %configure \
     --sysconfdir=%{_sysconfdir} \
     --libdir=%{_libdir}/quagga \
@@ -274,7 +264,7 @@
 
 %install
 mkdir -p %{buildroot}/etc/{quagga,sysconfig,logrotate.d,pam.d} \
-         %{buildroot}/var/log/quagga %{buildroot}%{_infodir}
+	%{buildroot}/var/log/quagga %{buildroot}%{_infodir}
 make DESTDIR=%{buildroot} INSTALL="install -p" CP="cp -p" install
 
 # Remove this file, as it is uninstalled and causes errors when building on RH9
@@ -318,19 +308,19 @@
 # add vty_group
 %if 0%{?vty_group:1}
 if getent group %vty_group > /dev/null ; then : ; else \
- /usr/sbin/groupadd -r -g %vty_gid %vty_group > /dev/null || : ; fi
+	/usr/sbin/groupadd -r -g %vty_gid %vty_group > /dev/null || : ; fi
 %endif
 
 # add quagga user and group
 %if 0%{?quagga_user:1}
 # Ensure that quagga_gid gets correctly allocated
 if getent group %quagga_user >/dev/null; then : ; else \
- /usr/sbin/groupadd -g %quagga_gid %quagga_user > /dev/null || : ; \
+	/usr/sbin/groupadd -g %quagga_gid %quagga_user > /dev/null || : ; \
 fi
 if getent passwd %quagga_user >/dev/null ; then : ; else \
- /usr/sbin/useradd  -u %quagga_uid -g %quagga_gid -G %vty_group \
-  -M -r -s /sbin/nologin -c "Quagga routing suite" \
-  -d %_localstatedir %quagga_user 2> /dev/null || : ; \
+	/usr/sbin/useradd  -u %quagga_uid -g %quagga_gid -G %vty_group \
+		-M -r -s /sbin/nologin -c "Quagga routing suite" \
+		-d %_localstatedir %quagga_user 2> /dev/null || : ; \
 fi
 %endif
 
@@ -348,23 +338,23 @@
 }
 
 zebra_spec_add_service zebrasrv 2600/tcp "zebra service"
-zebra_spec_add_service zebra    2601/tcp "zebra vty"
-zebra_spec_add_service ripd     2602/tcp "RIPd vty"
-zebra_spec_add_service ripngd   2603/tcp "RIPngd vty"
-zebra_spec_add_service ospfd    2604/tcp "OSPFd vty"
-zebra_spec_add_service bgpd     2605/tcp "BGPd vty"
-zebra_spec_add_service ospf6d   2606/tcp "OSPF6d vty"
+zebra_spec_add_service zebra	2601/tcp "zebra vty"
+zebra_spec_add_service ripd	2602/tcp "RIPd vty"
+zebra_spec_add_service ripngd	2603/tcp "RIPngd vty"
+zebra_spec_add_service ospfd	2604/tcp "OSPFd vty"
+zebra_spec_add_service bgpd	2605/tcp "BGPd vty"
+zebra_spec_add_service ospf6d	2606/tcp "OSPF6d vty"
 %if %{with_ospfapi}
-zebra_spec_add_service ospfapi  2607/tcp "OSPF-API"
+zebra_spec_add_service ospfapi	2607/tcp "OSPF-API"
 %endif
 %if %{with_isisd}
-zebra_spec_add_service isisd    2608/tcp "ISISd vty"
+zebra_spec_add_service isisd	2608/tcp "ISISd vty"
 %endif
 %if %{with_pimd}
-zebra_spec_add_service pimd     2611/tcp "PIMd vty"
+zebra_spec_add_service pimd	2611/tcp "PIMd vty"
 %endif
 %if %{with_nhrpd}
-zebra_spec_add_service nhrpd    2612/tcp "NHRPd vty"
+zebra_spec_add_service nhrpd	2612/tcp "NHRPd vty"
 %endif
 
 %if "%{initsystem}" == "systemd"
@@ -502,7 +492,7 @@
 	##
 	if [ "$1" = "0" ]; then
 		for daemon in %all_daemons ; do
-			/etc/rc.d/init.d/${daemon} stop  >/dev/null 2>&1
+			/etc/rc.d/init.d/${daemon} stop >/dev/null 2>&1
 			/sbin/chkconfig --del ${daemon}
 		done
 	fi
@@ -613,15 +603,15 @@
 %endif
 
 %changelog
-* Mon Feb 27 2017 Paul Jakma <paul@jakma.org> - %{version}
+* Mon Feb 27 2017 Paul Jakma <paul@jakma.org>
 - Apply 0001-systemd-various-service-file-improvements.patch from Fedora
 - Review Fedora spec file and sync up with any useful differences, inc:
 - Add tmpfiles.d config for Quagga from Fedora
 - Add quagga-filter-perl-requires.sh from Fedora.
-- Move libs to %{_libdir}/quagga as per Fedora
+- Move libs to %%{_libdir}/quagga as per Fedora
 - use systemd_postun_with_restart for postun
 
-* Tue Feb 14 2017 Timo Teräs <timo.teras@iki.fi> - %{version}
+* Tue Feb 14 2017 Timo Teräs <timo.teras@iki.fi>
 - add nhrpd
 
 * Thu Feb 11 2016 Paul Jakma <paul@jakma.org>