Sophie

Sophie

distrib > Mandriva > 8.2 > i586 > media > main-src > by-pkgid > c385f5deb7aba35f81ea1ad14ea67296 > files > 10

mgetty-1.1.28-2mdk.src.rpm

%define name 	mgetty
%define version 1.1.28
%define release 2mdk

Summary:	A getty replacement for use with data and fax modems.
Name:		%{name}
Version:	%{version}
Release:	%{release}
Source:		ftp://alpha.greenie.net:/pub/mgetty/source/1.1/%{name}%{version}-Jan10.tar.bz2
URL:		http://alpha.greenie.net/mgetty/
Patch0:		mgetty-1.1.14-config.patch.bz2
Patch1:		mgetty-1.1.5-makekvg.patch.bz2
Patch2:		mgetty-1.1.14-policy.patch.bz2
Patch3:		mgetty-1.1.5-strip.patch.bz2
Patch4:		mgetty-1.1.14-echo.patch.bz2
Patch5:		mgetty-1.1.14-logrotate.patch.bz2
Patch6:		mgetty-1.1.24-imakefile.patch.bz2
Patch8:		mgetty-1.1.21-noroot.patch.bz2
Patch9:		mgetty-1.1.21-linkman.patch.bz2
Requires:	libgr-progs
License:	GPL
Group:		Communications
BuildRequires:	XFree86-devel
Buildroot:	%{_tmppath}/%{name}-%{version}-root

%package sendfax
Summary:	Provides support for sending faxes over a modem.
Requires:	mgetty = %{version}-%{release}
Conflicts:	hylafax
Group:		Communications

%package voice
Summary:	A program for using your modem and mgetty as an answering machine.
Requires:	mgetty = %{version}-%{release}
Group:		Communications

%package viewfax
Summary:	An X Window System fax viewer.
Requires:	mgetty = %{version}-%{release}
Group:		Communications

%package contrib
Summary:	User contributed stuff that comes with %{name}.
Group:		Communications
AutoReqProv:	no

%description
The mgetty package contains a "smart" getty which allows logins over a
serial line (i.e., through a modem).  If you're using a Class 2 or 2.0
modem, mgetty can receive faxes.  If you also need to send faxes, you'll
need to install the sendfax program.

If you'll be dialing in to your system using a modem, you should install
the mgetty package.  If you'd like to send faxes using mgetty and your
modem, you'll need to install the mgetty-sendfax program.  If you need a
viewer for faxes, you'll also need to install the mgetty-viewfax package.

%description sendfax
Sendfax is a standalone backend program for sending fax files.  The
mgetty program (a getty replacement for handling logins over a serial
line) plus sendfax will allow you to send faxes through a Class 2 modem.

If you'd like to send faxes over a Class 2 modem, you'll need to install
the mgetty-sendfax and the mgetty packages.

%description voice
The mgetty-voice package contains the vgetty system, which enables
mgetty and your modem to support voice capabilities.  In simple terms,
vgetty lets your modem act as an answering machine.  How well the system
will work depends upon your modem, which may or may not be able to handle
this kind of implementation.

Install mgetty-voice along with mgetty if you'd like to try having your
modem act as an answering machine.

%description viewfax
Viewfax displays the fax files received using mgetty in an X11 window.
Viewfax is capable of zooming in and out on the displayed fax.

If you're installing the mgetty-viewfax package, you'll also need to
install mgetty.

%description contrib

The contents of the contrib directory that comes with %{name}.

%prep
%setup -q -n %{name}-%{version}
cp policy.h-dist policy.h
%patch0 -p1 -b .config
%patch1 -p1 -b .makekvg
%patch2 -p1
%patch3 -p1 -b .strip
%patch4 -p1 -b .echo
%patch5 -p1
%patch6 -p1
# new texinfo much stricter about xrefs
%patch8 -p1
%patch9 -p1

%build
%make
# 1.1.28-2mdk yves - ugly hack to have correct info dir
echo -e "\nSTART-INFO-DIR-ENTRY\n* mgetty: (mgetty).       A getty replacement use with data and fax modems.\nEND-INFO-DIR-ENTRY\n" >> doc/mgetty.info

cd voice
%make

cd ../frontends/X11/viewfax-2.5
xmkmf
make depend
%make CDEBUGFLAGS="$RPM_OPT_FLAGS"

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/var/spool -p $RPM_BUILD_ROOT/sbin
make prefix=$RPM_BUILD_ROOT/usr spool=$RPM_BUILD_ROOT/var/spool \
	CONFDIR=$RPM_BUILD_ROOT/etc/mgetty+sendfax install
install -m700 callback/callback $RPM_BUILD_ROOT/usr/sbin
install -m4711 callback/ct $RPM_BUILD_ROOT/usr/bin
strip $RPM_BUILD_ROOT/usr/bin/newslock

mv $RPM_BUILD_ROOT/usr/sbin/mgetty $RPM_BUILD_ROOT/sbin

# this conflicts with efax
mv $RPM_BUILD_ROOT/usr/man/man1/fax.1 $RPM_BUILD_ROOT/usr/man/man1/mgetty_fax.1

# voice mail extensions
(cd voice
mkdir -p $RPM_BUILD_ROOT/var/spool/voice 
mkdir -p $RPM_BUILD_ROOT/var/spool/voice/messages
mkdir -p $RPM_BUILD_ROOT/var/spool/voice/incoming

make prefix=$RPM_BUILD_ROOT/usr spool=$RPM_BUILD_ROOT/var/spool \
	CONFDIR=$RPM_BUILD_ROOT/etc/mgetty+sendfax install

mv $RPM_BUILD_ROOT/usr/sbin/vgetty $RPM_BUILD_ROOT/sbin
install -m 600 -c voice.conf-dist $RPM_BUILD_ROOT/etc/mgetty+sendfax/voice.conf
)
find samples -type f -exec chmod 644 {} \;

(cd frontends/X11/viewfax-2.5
make DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} HELPDIR=%{_libdir}/mgetty+sendfax install
make DESTDIR=$RPM_BUILD_ROOT MANDIR=/usr/man/man1 install.man
)

mkdir -p $RPM_BUILD_ROOT/etc/logrotate.d
install -m 0644 logrotate.mgetty $RPM_BUILD_ROOT/etc/logrotate.d/mgetty
install -m 0644 logrotate.sendfax $RPM_BUILD_ROOT/etc/logrotate.d/sendfax

#move the man pages
mkdir -p $RPM_BUILD_ROOT/usr/share
mv $RPM_BUILD_ROOT/usr/man $RPM_BUILD_ROOT/usr/share
#move the info page
#mkdir $RPM_BUILD_ROOT/usr/share
mv $RPM_BUILD_ROOT/usr/info $RPM_BUILD_ROOT/usr/share

# yves - 1.1.26-4mdk - doc with good perm
find doc -type f -exec chmod 644 {} \;
chmod -f 0644 BUGS

%clean
rm -rf $RPM_BUILD_ROOT

%post
%_install_info %{name}.info

%postun
if [ $1 = 0 ]; then
  %{__rm} -fr /var/log/mgetty.log*
fi
%_remove_install_info %{name}.info

%postun sendfax
if [ $1 = 0 ]; then
  %{__rm} -fr /var/log/sendfax.log*
fi


%files
%defattr(-,root,root)
%doc ChangeLog README.1st THANKS TODO Recommend FTP samples/*
%doc doc/mgetty.ps doc/mgetty.dvi doc/mgetty.texi  doc/fhng-codes doc/modems.db
%doc BUGS doc/*.txt
%attr(755,root,root) /sbin/mgetty
%{_mandir}/man8/mgetty.8*
%{_mandir}/man8/callback.8*
%{_mandir}/man8/faxrunqd.8*
%{_mandir}/man4/mgettydefs.4*
%{_infodir}/mgetty.info*
%dir %{_sysconfdir}/mgetty+sendfax
%attr(644,root,root) %config(noreplace) %{_sysconfdir}/mgetty+sendfax/login.config
%attr(644,root,root) %config(noreplace) %{_sysconfdir}/mgetty+sendfax/mgetty.config
%attr(644,root,root) %config(noreplace) %{_sysconfdir}/mgetty+sendfax/dialin.config
%config(noreplace) %{_sysconfdir}/logrotate.d/mgetty


%files sendfax
%defattr(-,root,root)

%dir %{_var}/spool/fax
%dir %{_var}/spool/fax/incoming
%dir %{_var}/spool/fax/outgoing
%dir %{_var}/spool/fax/outgoing/locks

%{_bindir}/kvg
%{_bindir}/newslock
%{_bindir}/g3cat
%{_bindir}/g32pbm
%{_bindir}/pbm2g3
%{_bindir}/faxspool
%attr(755,root,root) %{_bindir}/faxrunq
%{_bindir}/faxq
%{_bindir}/cutbl
%{_bindir}/faxrm
%attr(755,root,root) %{_bindir}/ct
%attr(755,root,root) %{_sbindir}/sendfax
%attr(755,root,root) %{_sbindir}/faxrunqd
%attr(755,root,root) %{_sbindir}/callback
%dir	%{_libexecdir}/mgetty+sendfax
%{_libexecdir}/mgetty+sendfax/cour25.pbm
%{_libexecdir}/mgetty+sendfax/cour25n.pbm
%{_mandir}/man1/g32pbm.1*
%{_mandir}/man1/pbm2g3.1*
%{_mandir}/man1/g3cat.1*
%{_mandir}/man1/mgetty_fax.1*
%{_mandir}/man1/faxspool.1*
%{_mandir}/man1/faxrunq.1*
%{_mandir}/man1/faxq.1*
%{_mandir}/man1/faxrm.1*
%{_mandir}/man1/coverpg.1*
%{_mandir}/man5/faxqueue.5*
%{_mandir}/man8/sendfax.8*
%attr(644,root,root) %config(noreplace) %{_sysconfdir}/mgetty+sendfax/sendfax.config
%attr(644,root,root) %config(noreplace) %{_sysconfdir}/mgetty+sendfax/faxrunq.config
%config(noreplace) %{_sysconfdir}/mgetty+sendfax/faxheader
%config(noreplace) %{_sysconfdir}/logrotate.d/sendfax

%files voice
%defattr(-,root,root)
%dir %{_var}/spool/voice
%dir %{_var}/spool/voice/incoming
%dir %{_var}/spool/voice/messages

%attr(755,root,root) /sbin/vgetty
%{_bindir}/vm
%{_bindir}/pvfamp
%{_bindir}/pvfcut
%{_bindir}/pvfecho
%{_bindir}/pvffile
%{_bindir}/pvffilter
%{_bindir}/pvfnoise
%{_bindir}/pvffft
%{_bindir}/pvfmix
%{_bindir}/pvfreverse
%{_bindir}/pvfsine
%{_bindir}/pvfspeed
%{_bindir}/pvftormd
%{_bindir}/rmdtopvf
%{_bindir}/rmdfile
%{_bindir}/pvftovoc
%{_bindir}/voctopvf
%{_bindir}/pvftolin
%{_bindir}/lintopvf
%{_bindir}/pvftobasic
%{_bindir}/basictopvf
%{_bindir}/pvftoau
%{_bindir}/autopvf
%{_bindir}/pvftowav
%{_bindir}/wavtopvf

%{_mandir}/man1/zplay.1*
%{_mandir}/man1/pvf.1*
%{_mandir}/man1/pvfamp.1*
%{_mandir}/man1/pvfcut.1*
%{_mandir}/man1/pvfecho.1*
%{_mandir}/man1/pvffile.1*
%{_mandir}/man1/pvffft.1*
%{_mandir}/man1/pvfmix.1*
%{_mandir}/man1/pvfreverse.1*
%{_mandir}/man1/pvfsine.1*
%{_mandir}/man1/pvfspeed.1*
%{_mandir}/man1/pvftormd.1*
%{_mandir}/man1/rmdtopvf.1*
%{_mandir}/man1/rmdfile.1*
%{_mandir}/man1/pvftovoc.1*
%{_mandir}/man1/voctopvf.1*
%{_mandir}/man1/pvftolin.1*
%{_mandir}/man1/lintopvf.1*
%{_mandir}/man1/pvftobasic.1*
%{_mandir}/man1/basictopvf.1*
%{_mandir}/man1/pvftoau.1*
%{_mandir}/man1/autopvf.1*
%{_mandir}/man1/pvftowav.1*
%{_mandir}/man1/wavtopvf.1*
%attr(644,root,root) %config(noreplace) %{_sysconfdir}/mgetty+sendfax/voice.conf

%files viewfax
%defattr(-,root,root)
%doc frontends/X11/viewfax-2.5/C* frontends/X11/viewfax-2.5/README
%{_bindir}/viewfax
%dir %{_libexecdir}/mgetty+sendfax
%{_libexecdir}/mgetty+sendfax/viewfax.tif
%{_mandir}/man1/viewfax.1x.*

%files contrib
%defattr(644,root,root,755)
%doc contrib/*


%changelog
* Sat Mar 09 2002 Yves Duret <yduret@mandrakesoft.com> 1.1.28-2mdk
- fix no entry in info dir file (#4209)

* Sat Jan 26 2002 Yves Duret <yduret@mandrakesoft.com> 1.1.28-1mdk
- version 1.1.28

* Sat Nov 10 2001 Yves Duret <yduret@mandrakesoft.com> 1.1.27-1mdk
- version 1.1.27

* Tue Aug 28 2001 Yves Duret <yduret@mandrakesoft.com> 1.1.26-4mdk
- corrected file perm (oops i did it again!)

* Tue Aug 28 2001 Yves Duret <yduret@mandrakesoft.com> 1.1.26-3mdk
- corrected file perm

* Mon Jul 16 2001 Yves Duret <yduret@mandrakesoft.com> 1.1.26-2mdk
- rebuild
- spec clean up

* Tue May  1 2001 Yves Duret <yduret@mandrakesoft.com> 1.1.26-1mdk
- 1.1.26 out for genral comsumption

* Sat Mar 17 2001 Yves Duret <yduret@mandrakesoft.com> 1.1.25-2mdk
- removed Conflicts tag on mgetty-viewfax (only needed on mgetty-sendfax)

* Wed Mar 14 2001 Yves Duret <yduret@mandrakesoft.com> 1.1.25-1mdk
- 1.2.25 
- added Conflicts: hylafax in fax subpackages
- update Requires:

* Wed Jan 10 2001 Vincent Danen <vdanen@mandrakesoft.com> 1.1.24-1mdk
- 1.1.24 (security fixes for tmpfile insecurities)

* Wed Jan 10 2001 Yves Duret <yduret@mandrakesoft.com> 1.1.22-3mdk
- macros
- s/Copyright/License/

* Tue Sep 26 2000 Etienne Faure  <etienne@mandraksoft.com> 1.1.22-2mdk
- Added (noreplace) tag to conffiles

* Thu Aug 31 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 1.1.22-1mdk
- 1.1.22 fix security.

* Tue Aug 29 2000 Etienne Faure <etienne@mandrakesoft.com> 1.1.21-8mdk
- use the _mandir & _infodir macros

* Mon Aug 07 2000 Frederic Lepied <flepied@mandrakesoft.com> 1.1.21-7mdk
- automatically added BuildRequires

* Thu Jul 19 2000 Etienne Faure <etienne@mandrakesoft.com> 1.1.21-6mdk
- rebuild on kenobi
- Changed permission of source files: 664 -> 644

* Fri Mar 31 2000 Frederic Lepied <flepied@mandrakesoft.com> 1.1.21-5mdk
- group fix.

* Fri Nov 26 1999 Florent Villard <warly@mandrakesoft.com>
- Mandrake adaptation
- clean the install script

* Sun Aug 15 1999 Nick Urbanik <nicku@vtc.edu.hk>
- Signed it.

* Sat Aug 14 1999 Nick Urbanik <nicku@vtc.edu.hk>
- updated to 1.1.21
- Created the contrib package (marginally worthwhile)
- Added more documentation to mgetty
- Added more programs to sendfax and voice.

* Tue Apr  6 1999 Bill Nottingham <notting@redhat.com>
- strip setuid bit from ct

* Tue Mar 23 1999 Preston Brown <pbrown@redhat.com>
- better log handling

* Wed Jan 06 1999 Cristian Gafton <gafton@redhat.com>
- rebuild for glibc 2.1

* Sat Aug 22 1998 Jos Vos <jos@xos.nl>
- Use a patch for creating policy.h using policy.h-dist.
- Add viewfax subpackage (X11 fax viewing program).
- Add logrotate config files for mgetty and sendfax log files.
- Properly define ECHO in Makefile for use with bash.
- Add optional use of dialin.config (for modems supporting this).
- Change default notification address to "root" (was "faxadmin").
- Change log file names according to better defaults.
- Change default notify program to /etc/mgetty+sendfax/new_fax (was
  /usr/local/bin/new_fax).

* Fri Aug 21 1998 Jeff Johnson <jbj@redhat.com>
- add faxrunqd man page (problem #850)
- add missing pbm2g3 (and man page); remove unnecessary "rm -f pbmtog3"
- delete redundant ( cd tools; make ... )

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

* Fri Apr 10 1998 Cristian Gafton <gafton@redhat.com>
- updated to 1.1.14
- AutoPPP patch
 
* Thu Dec 18 1997 Mike Wangsmo <wanger@redhat.com>
- added more of the documentation files to the rpm

* Wed Oct 29 1997 Otto Hammersmith <otto@redhat.com>
- added install-info support

* Tue Oct 21 1997 Otto Hammersmith <otto@redhat.com>
- updated version

* Wed Oct 15 1997 Erik Troan <ewt@redhat.com>
- now requires libgr-progs instead of netpbm

* Mon Aug 25 1997 Erik Troan <ewt@redhat.com>
- built against glibc