Summary: The inetd networking program.
Summary(ja): inetd ネットワークプログラム
Name: inetd
Version: 0.17
Release: 0vl4
License: BSD
Group: System Environment/Daemons
Source0: ftp://sunsite.unc.edu/pub/Linux/system/network/netkit/netkit-base-%{version}.tar.gz
Source1: inetd.conf.default.vine
Source2: inet.init
Source3: inetd.conf.5
Patch0: netkit-base-0.16-jbj.patch
Patch2: netkit-base-0.16-mandir.patch
Prereq: chkconfig
Requires: tcp_wrappers
Obsoletes: netkit-base

BuildRoot: %{_tmppath}/%{name}-%{version}-root

Vendor: Project Vine
Distribution: Vine Linux

%description
The inetd package contains the inetd networking program. Inetd listens
on certain Internet sockets for connection requests, decides what
program should receive each request, and starts that program.

The inetd package should be installed on any machine that is on a
network.


%description -l ja
inetd パッケージは基本的なネットワークツールである inetd を含んでいる。
inetd はあるインターネットのコネクション要求のソケットを監視し、それぞれの要求に対してどのプログラムがそれを受けとるか決定し、そのプログラムを開始する。

inetd パッケージはネットワークに接続するどのマシンにもインストールすべきである。

%prep
%setup -q -n netkit-base-%{version}
%patch0 -p1 -b .jbj
%patch2 -p1 -b .mandir

%build
sh configure
perl -pi -e 's,-O2,\$(RPM_OPT_FLAGS),' MCONFIG

make

%install
rm -rf $RPM_BUILD_ROOT

mkdir -p $RPM_BUILD_ROOT%{_mandir}/man8
mkdir -p $RPM_BUILD_ROOT%{_sbindir}
make INSTALLROOT=$RPM_BUILD_ROOT install

mkdir -p $RPM_BUILD_ROOT%{_mandir}/man5
install -m 644 $RPM_SOURCE_DIR/inetd.conf.5 $RPM_BUILD_ROOT%{_mandir}/man5

mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/{init,rc0,rc1,rc2,rc3,rc4,rc5,rc6}.d
install -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/inetd.conf
install -m 755 %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/inet

%clean
rm -rf $RPM_BUILD_ROOT

%post
/sbin/chkconfig --add inet

%preun
if [ $1 = 0 ]; then
    /sbin/chkconfig --del inet
fi

%triggerpostun -- netkit-base
/sbin/chkconfig --add inet

%files
%defattr(-,root,root)
%attr(0644,root,root)	%config(noreplace) %{_sysconfdir}/inetd.conf
%attr(0755,root,root)	%config %{_sysconfdir}/rc.d/init.d/inet
%{_mandir}/man5/inetd.conf.5*
%{_mandir}/man8/inetd.8*
%{_sbindir}/inetd

%changelog
* Sun Nov 26 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 0.17-0vl4
- fix dependencies ([VineSeed:11559,12368], <bts:398>)
  - remove Conflicts: xinetd
  - update inet.init (Source2) not to start inetd if xinetd is installed

* Tue May 30 2006 Shu KONNO <owa@bg.wakwak.com> 0.17-0vl3
- s/Copyright/License/

* Sun Feb 20 2005 Daisuke SUZUKI <daisuke@linux.or.jp> 0.17-0vl2
- add Conflicts: xinetd

* Sat Apr 17 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 0.17-0vl1
- new upstream release
- disable telnetd by default

* Sat Oct 04 2003 KAZUKI SHIMURA <rito@pos.to> 0.16-7vl4
- fix description (ja)

* Sat Mar 09 2002 Daisuke SUZUKI <daisuke@linux.or.jp> 0.16-7vl3
- comment out more service from inetd.conf

* Thu Feb 15 2001 Satoshi MACHINO <machoino@vinelinux.org> 0.16-7vl2
- added netkit-base-0.16-mandir.patch to move mandir 
  to /usr/share/man from /usr/man

* Wed Feb 14 2001 Satoshi MACHINO <machoino@vinelinux.org> 0.16-7vl1
- use an improved patch for closing sockets from pekkas@netcore.fi
  (#11548)
- used rpmmacros for Vine Linux 2.1.5

* Wed Jan 24 2001 KAJIKI Yoshihiro <kajiki@ylug.org>
- correct option of proftpd on %{_sysconfdir}/inetd.conf

* Thu Aug  3 2000 Jun Nishii <jun@vinelinux.org>
- adapt to Vine Linux 2.0

* Mon Jan 31 2000 Cristian Gafton <gafton@redhat.com>
- man pages are compressed
- rebuild to fix dependencies

* Mon Jan 17 2000 Bill Nottingham <notting@redhat.com>
- remove identd from inetd.conf

* Tue Jan  4 2000 Bill Nottingham <notting@redhat.com>
- remove chkconfig links from file list
- add trigger to fix links disappearing on upgrade from netkit-base

* Fri Dec 24 1999 Jeff Johnson <jbj@redhat.com>
- update to 0.16.
- rename package to inetd, ANK ping can be found in new package iputils.
- permit non-root builds (ping 4755 root.root has %attr in file list).

* Fri Sep 10 1999 Bill Nottingham <notting@redhat.com>
- chkconfig --del in %preun, not %postun

* Sat Sep  4 1999 Jeff Johnson <jbj@redhat.com>
- revert identd to inetd.conf startup.

* Thu Aug 19 1999 Jeff Johnson <jbj@redhat.com>
- correct identd inetd.conf startup to wait and comment out (#4504).

* Mon Aug 16 1999 Bill Nottingham <notting@redhat.com>
- initscript munging

* Mon Aug  9 1999 Jeff Johnson <jbj@redhat.com>
- don't compare timevals -- rtt > 1sec causes failure (#4443,#3960).
- resurrect old -c 2 behavior if host is unreachable (#3959).
- update ping to ANK's ss990610 with new "-w waitsecs" option.

* Tue Jul 27 1999 Bill Nottingham <notting@redhat.com>
- run talk/talkd as nobody.tty
- run fingerd as nobody
- fix description in init file

* Mon May 17 1999 Jeff Johnson <jbj@redhat.com)
- fix 64bit alpha problems. (#1786)

* Wed May  5 1999 Jeff Johnson <jbj@redhat.com>
- use ping from iputils.
- fix odd-byte checksum on little-endian machines (#2281)
- (re-) verify ping flood (#213).

* Wed Apr  7 1999 Jeff Johnson <jbj@redhat.com>
- fix inetd fd leak (#695)

* Wed Mar 31 1999 Jeff Johnson <jbj@redhat.com>
- ping flood can send faster than it can receive -- staunch the flow. (#213)

* Tue Mar 30 1999 Bill Nottingham <notting@redhat.com>
- turn off imap/pop by default
- add a buffer overflow patch

* Fri Mar 26 1999 Jeff Johnson <jbj@redhat.com>
- make inetd.conf %config(noreplace).
- fix time service config (#1725).

* Fri Mar 26 1999 Preston Brown <pbrown@redhat.com>
- comsat service added (commented out)

* Tue Mar 23 1999 Preston Brown <pbrown@redhat.com>
- man page added

* Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com> 
- auto rebuild in the new build environment (release 23)

* Mon Mar 15 1999 Jeff Johnson <jbj@redhat.com>
- compile for 6.0.

* Wed Jun 17 1998 Jeff Johnson <jbj@redhat.com>
- man page correction (problem #727)
- add build root.

* Fri Jun 05 1998 Prospector System <bugs@redhat.com>
- translations modified for de

* Thu Jun 04 1998 Mike Wangsmo <wanger@redhat.com>
- made %{_sysconfdir}/inetd.conf a %config file.  This is a D'oh!

* Mon May 04 1998 Michael K. Johnson <johnsonm@redhat.com>
- fixed iniscript enhancement

* Fri Apr 24 1998 Prospector System <bugs@redhat.com>
- translations modified for de, fr, tr

* Thu Apr 23 1998 Michael K. Johnson
- enhanced initscript

* Wed Oct 29 1997 Donnie Barnes <djb@redhat.com>
- added %config(missingok) to init symlinks

* Sun Oct 19 1997 Erik Troan <ewt@redhat.com>
- turned off in runlevel 2
- added status, restart options to init script

* Mon Oct 13 1997 Erik Troan <ewt@redhat.com>
- added chkconfig support

* Wed Aug 27 1997 Erik Troan <ewt@redhat.com>
- fixed init.d symlinks
- fixed permissions on /etc/rc.d/inet
