File uucp.spec of Package sendmail

# spec file for package uucp (Version 1.07)
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via

# norootforbuild

Name:           uucp
License:        GPLv2+
Group:          Productivity/Networking/Other
PreReq:         fileutils %install_info_prereq
Requires:       /usr/bin/rmail filesystem netcfg
Recommends:     stunnel
AutoReqProv:    on
Version:        1.07
Release:        430
Summary:        Taylor UUCP
Source0:        uucp-1.07.tar.bz2
Source1:        uucpcfg.tar.bz2
Source2:        uucp.xinetd
Source3:        suucp.xinetd
Patch0:         uucp-1.07.dif
Patch1:         uucp-1.07-contrib.dif
Patch2:         uucp-1.07-grade.patch
Patch3:         uucp-1.07-cu.patch
Patch4:         uucp-1.07-lockdev.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  lockdev-devel pkg-config

Ian Taylor's Unix to Unix copy: mail and news over modem lines. This is
the standard UUCP package from the Free Software Foundation. It is
configured to use HoneyDanBer or Taylor configuration files. With
version 6.0 of SuSE Linux, the configuration directory has been moved
to /etc/uucp. Exactly: Taylor config:	    /etc/uucp HoneyDanBer
config:  /etc/uucp/hdb_config If you have your own setup under
/var/lib/uucp, please move it to /etc/uucp. Example configurations can
be found in /usr/share/doc/packages/uucp.

We did not include a uucp guest account. If you want to create a guest
account, make sure the directory /var/spool/uucppublic exists.

    Ian Lance Taylor <>

%patch -P 1     -b .cont
%patch -P 2 -p0 -b .grad
%patch -P 3 -p0 -b .cu
%patch -P 4 -p0 -b .lockdev
%patch -P 0

    ID=$(id -u)
    RPM_OPT_FLAGS="${RPM_OPT_FLAGS} -fno-strict-aliasing"
    %{?suse_update_config:%{suse_update_config -f}}
    CFLAGS="-Wall ${RPM_OPT_FLAGS} -pipe -D_GNU_SOURCE" \
    ./configure \
	--with-newconfigdir=/etc/uucp \
	--with-oldconfigdir=/etc/uucp/hdb_config \
	--prefix=/usr --mandir=%{_mandir} --infodir=%{_infodir}
    make CFLAGS="-Wall ${RPM_OPT_FLAGS} -pipe -D_GNU_SOURCE"

    ID=$(id -u)
    if test "$ID" -ne 0 ; then
	mkdir bin
	(cat > bin/install)<<-EOF
	while test \$# -gt 0; do
	    case "\$1" in
	    -o) shift 2;;
	    -g) shift 2;;
	    *)  argv="\${argv:+"\$argv "}\$1"
	set -- \$(echo \${argv})
	exec -a install /usr/bin/install \${1+"\$@"}
	chmod 755 bin/install
	type -p install
    mkdir -p -m 755 ${RPM_BUILD_ROOT}/etc/uucp/hdb_config
    mkdir -p -m 755 ${RPM_BUILD_ROOT}/etc/logrotate.d
    install -m 644 logrotate ${RPM_BUILD_ROOT}/etc/logrotate.d/uucp
    make DESTDIR=${RPM_BUILD_ROOT} install install-info
    mkdir -p -m 755 ${RPM_BUILD_ROOT}/var/spool/uucp ${RPM_BUILD_ROOT}/var/spool/uucppublic
    test "$ID" -ne 0 || \
    chown uucp:uucp ${RPM_BUILD_ROOT}/var/spool/uucp
    install -m 644 README.suse ${RPM_BUILD_ROOT}/var/spool/uucppublic/README
    mkdir -p -m 755 ${RPM_BUILD_ROOT}/usr/lib/uucp
    mv ${RPM_BUILD_ROOT}/usr/sbin/uu* ${RPM_BUILD_ROOT}/usr/lib/uucp/
    for x in ${RPM_BUILD_ROOT}/usr/lib/uucp/* ; do
	echo ${x##*/}
	ln -fs /usr/lib/uucp/${x##*/} ${RPM_BUILD_ROOT}/usr/sbin/
    rm -rf ${RPM_BUILD_ROOT}%{_defaultdocdir}/uucp
    mkdir -p ${RPM_BUILD_ROOT}%{_defaultdocdir}/uucp
    mkdir -p ${RPM_BUILD_ROOT}/var/log/uucp
    test "$ID" -ne 0 || \
    chown uucp:uucp ${RPM_BUILD_ROOT}/var/log/uucp
    tar jxvfpC %{SOURCE1} ${RPM_BUILD_ROOT}%{_defaultdocdir}/uucp
    chmod -R u+r,o+r,g+r ${RPM_BUILD_ROOT}%{_defaultdocdir}/uucp/
    mkdir -p -m 755 ${RPM_BUILD_ROOT}/etc/xinetd.d
    install -m 644 %{SOURCE2} ${RPM_BUILD_ROOT}/etc/xinetd.d/uucp
    install -m 644 %{SOURCE3} ${RPM_BUILD_ROOT}/etc/xinetd.d/suucp

%install_info --info-dir=%{_infodir} %{_infodir}/

%install_info_delete --info-dir=%{_infodir} %{_infodir}/
%verify_permissions -e /var/spool/uucppublic

%config(noreplace) /etc/logrotate.d/uucp
%config(noreplace) /etc/xinetd.d/uucp
%config(noreplace) /etc/xinetd.d/suucp
#%dir %attr(0750,uucp,uucp) /etc/uucp
%dir %attr(0750,uucp,uucp) /etc/uucp/hdb_config
%dir /usr/lib/uucp
%dir %attr(0755,uucp,uucp) /var/log/uucp
%verify(not mode group) %dir %attr(1770,root,uucp) /var/spool/uucppublic
#%dir %attr(0700,uucp,uucp) /var/spool/uucp
%attr(755,root,root) /usr/bin/cu
%attr(6555,uucp,uucp) /usr/bin/uucp
%attr(6555,uucp,uucp) /usr/bin/uuname
%attr(6555,uucp,uucp) /usr/bin/uustat
%attr(6555,uucp,uucp) /usr/bin/uux
%doc %{_infodir}/*.gz
%attr(6555,uucp,uucp) /usr/lib/uucp/uucico
%attr(6555,uucp,uucp) /usr/lib/uucp/uuxqt
%doc %{_mandir}/man1/cu.1.gz
%doc %{_mandir}/man1/uucp.1.gz
%doc %{_mandir}/man1/uustat.1.gz
%doc %{_mandir}/man1/uux.1.gz
%doc %{_mandir}/man8/uucico.8.gz
%doc %{_mandir}/man8/uuxqt.8.gz
%doc %{_defaultdocdir}/uucp
%attr(0640,root,uucp) %{_defaultdocdir}/uucp/cfg_example/taylor_config/call
%attr(0640,root,uucp) %{_defaultdocdir}/uucp/cfg_example/taylor_config/passwd

openSUSE Build Service is sponsored by