A new user interface for you! Read more...

File rinetd.spec of Package rinetd

Summary: TCP redirection server
Name: rinetd
Version: 0.62
Release: 11%{?dist}
License: GPLv2+
Group: System Environment/Daemons
URL: http://www.boutell.com/rinetd
Source0: http://www.boutell.com/rinetd/http/rinetd.tar.gz 
Source1: rinetd.conf
Source2: rinetd.init
Source3: rinetd.logrotate
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
PreReq: /sbin/chkconfig
PreReq: /sbin/service

%description
rinetd is a daemon which redirects TCP connections from one IP address
and port to another IP address and port. This daemon is often used to
access services behind a firewall.

%prep
%setup -q -n %{name}

%build
make CFLAGS="$RPM_OPT_FLAGS" %{?_smp_mflags}

%install
rm -rf $RPM_BUILD_ROOT

mkdir -p $RPM_BUILD_ROOT%{_sbindir}
install -p -m 0755 rinetd $RPM_BUILD_ROOT%{_sbindir}

mkdir -p $RPM_BUILD_ROOT%{_mandir}/man8
install -p -m 0644 rinetd.8 $RPM_BUILD_ROOT%{_mandir}/man8

mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d
install -p -m 0644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}
install -p -m 0755 %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/rinetd
install -p -m 0644 %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/rinetd

%clean
rm -rf $RPM_BUILD_ROOT

%post
/sbin/chkconfig --add rinetd

%preun
if [ "$1" -eq 0 ]; then
	/sbin/service rinetd stop > /dev/null 2>&1 ||:
	/sbin/chkconfig --del rinetd
fi
						
%postun
if [ "$1" -ge 1 ]; then
	/sbin/service rinetd condrestart > /dev/null 2>&1 ||:
fi

%files
%defattr(-, root, root)
%doc CHANGES README index.html
%{_sbindir}/*
%{_mandir}/man8/*
%config(noreplace) %{_sysconfdir}/rinetd.conf
%config %{_sysconfdir}/rc.d/init.d/rinetd
%config(noreplace) %{_sysconfdir}/logrotate.d/rinetd

%changelog
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.62-11
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild

* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.62-10
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.62-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.62-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Fri Feb 15 2008 Chris Ricker <kaboom@oobleck.net> 0.62-7
- fix license field
- rebuild for GCC 4.3

* Mon Sep 11 2006 Chris Ricker <kaboom@oobleck.net> 0.62-6
- Bump and rebuild

* Tue Feb 14 2006 Chris Ricker <kaboom@oobleck.net> 0.62-5
- rebuild for FC5

* Thu Jun 30 2005 Chris Ricker <kaboom@oobleck.net> 0.62-4
- use SIGHUP for reload in init script (Ville Skyttä)
- example config file made mode 0644 (Ville Skyttä)
- Add dist tag

* Fri Jun 02 2005 Chris Ricker <kaboom@oobleck.net> 0.62-3
- Fix %%preun script
- install instead of cp and %%attr (Ville Skyttä)

* Thu Apr 28 2005 Chris Ricker <kaboom@oobleck.net> 0.62-2
- Really include the logrotate file this time

* Tue Apr 26 2005 Chris Ricker <kaboom@oobleck.net> 0.62-1
- Initial package