auto-import sendmail-8.12.5-7 from sendmail-8.12.5-7.src.rpm
This commit is contained in:
parent
02cf87ea15
commit
0927cabbcc
103
sendmail.spec
103
sendmail.spec
@ -1,9 +1,11 @@
|
||||
%define optflags -O2 -fno-strict-aliasing
|
||||
|
||||
%define initdir /etc/rc.d/init.d
|
||||
# If you want to build this on older Red Hat Linux releases, this defines
|
||||
# the version number to build on. Supported should be 62 70 71 72 for
|
||||
# Red Hat Linux 6.2 up to 7.2 and "100" for the current rawhide version.
|
||||
%define errata 100
|
||||
%define release 6
|
||||
%define release 7
|
||||
|
||||
%if %{errata} <= 70
|
||||
%define sendmailcf usr/lib/sendmail-cf
|
||||
@ -129,82 +131,50 @@ fi
|
||||
%patch4 -p1
|
||||
%patch5 -p1
|
||||
%patch6 -p1
|
||||
%patch7 -p1 -b .pid
|
||||
%patch7 -p1
|
||||
|
||||
%build
|
||||
pushd libmilter
|
||||
sh Build -f ../redhat.config.m4
|
||||
popd
|
||||
|
||||
pushd libsmutil
|
||||
sh Build -f ../redhat.config.m4
|
||||
popd
|
||||
|
||||
pushd sendmail
|
||||
sh Build -f ../redhat.config.m4
|
||||
popd
|
||||
|
||||
pushd mailstats
|
||||
sh Build -f ../redhat.config.m4
|
||||
popd
|
||||
|
||||
pushd rmail
|
||||
sh Build -f ../redhat.config.m4
|
||||
popd
|
||||
|
||||
pushd praliases
|
||||
sh Build -f ../redhat.config.m4
|
||||
popd
|
||||
|
||||
pushd smrsh
|
||||
sh Build -f ../redhat.config.m4
|
||||
popd
|
||||
|
||||
pushd makemap
|
||||
sh Build -f ../redhat.config.m4
|
||||
popd
|
||||
for i in libmilter libsmutil sendmail mailstats rmail praliases \
|
||||
smrsh makemap ; do
|
||||
pushd $i
|
||||
sh Build -f ../redhat.config.m4
|
||||
popd
|
||||
done
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
mkdir -p $RPM_BUILD_ROOT
|
||||
|
||||
cd $RPM_BUILD_ROOT
|
||||
mkdir -p etc/sysconfig $RPM_BUILD_ROOT%{initdir} etc/pam.d
|
||||
mkdir -p usr/bin usr/include/libmilter usr/lib .%{_mandir}/man{1,5,8} usr/sbin var/log
|
||||
mkdir -p var/spool %{sendmailcf}
|
||||
mkdir -p etc/sysconfig .%{initdir} etc/pam.d
|
||||
mkdir -p usr/bin usr/include/libmilter usr/lib .%{_mandir}/man{1,5,8}
|
||||
mkdir -p usr/sbin var/log var/spool %{sendmailcf}
|
||||
cd -
|
||||
|
||||
OBJDIR=obj.$(uname -s).$(uname -r).$(arch)
|
||||
|
||||
nameuser=`id -nu`
|
||||
namegroup=`id -ng`
|
||||
|
||||
Make() {
|
||||
make $@ \
|
||||
DESTDIR=$RPM_BUILD_ROOT \
|
||||
MANROOT=%{_mandir}/man \
|
||||
SBINOWN=${nameuser} \
|
||||
SBINGRP=${namegroup} \
|
||||
UBINOWN=${nameuser} \
|
||||
UBINGRP=${namegroup} \
|
||||
MANOWN=${nameuser} \
|
||||
MANGRP=${namegroup} \
|
||||
INCOWN=${nameuser} \
|
||||
INCGRP=${namegroup} \
|
||||
LIBOWN=${nameuser} \
|
||||
LIBGRP=${namegroup} \
|
||||
GBINOWN=${nameuser} \
|
||||
GBINGRP=${namegroup} \
|
||||
MSPQOWN=${nameuser} \
|
||||
CFOWN=${nameuser} \
|
||||
CFGRP=${namegroup}
|
||||
SBINOWN=${nameuser} SBINGRP=${namegroup} \
|
||||
UBINOWN=${nameuser} UBINGRP=${namegroup} \
|
||||
MANOWN=${nameuser} MANGRP=${namegroup} \
|
||||
INCOWN=${nameuser} INCGRP=${namegroup} \
|
||||
LIBOWN=${nameuser} LIBGRP=${namegroup} \
|
||||
GBINOWN=${nameuser} GBINGRP=${namegroup} \
|
||||
CFOWN=${nameuser} CFGRP=${namegroup} \
|
||||
MSPQOWN=${nameuser}
|
||||
}
|
||||
|
||||
Make install -C $OBJDIR/libmilter
|
||||
Make install -C $OBJDIR/libsmutil
|
||||
Make install -C $OBJDIR/sendmail
|
||||
Make install -C $OBJDIR/mailstats
|
||||
Make install -C $OBJDIR/praliases
|
||||
Make force-install -C $OBJDIR/rmail
|
||||
Make install -C $OBJDIR/praliases
|
||||
Make install -C $OBJDIR/smrsh
|
||||
Make install -C $OBJDIR/makemap
|
||||
|
||||
@ -244,7 +214,8 @@ sed -e 's|/%{sendmailcf}|\.\.|' < $RPM_BUILD_ROOT/etc/mail/sendmail.mc > cf/cf/r
|
||||
install -m 644 cf/cf/redhat.cf $RPM_BUILD_ROOT/etc/mail/sendmail.cf
|
||||
install -m 644 cf/cf/submit.mc $RPM_BUILD_ROOT/etc/mail/submit.mc
|
||||
|
||||
echo "# local-host-names - include all aliases for your machine here." > $RPM_BUILD_ROOT/etc/mail/local-host-names
|
||||
echo "# local-host-names - include all aliases for your machine here." \
|
||||
> $RPM_BUILD_ROOT/etc/mail/local-host-names
|
||||
( echo "# trusted-users - users that can send mail as others without a warning"
|
||||
echo "# apache, mailman, majordomo, uucp, are good candidates" ) \
|
||||
> $RPM_BUILD_ROOT/etc/mail/trusted-users
|
||||
@ -266,10 +237,9 @@ root=..
|
||||
while [ ! -r $RPM_BUILD_ROOT/%{_bindir}/${root}/rootfile ] ; do
|
||||
root=${root}/..
|
||||
done
|
||||
for f in hoststat mailq newaliases purgestat
|
||||
do
|
||||
for f in hoststat mailq newaliases purgestat ; do
|
||||
ln -sf ${root}%{_sbindir}/sendmail $RPM_BUILD_ROOT%{_bindir}/${f}
|
||||
done
|
||||
done
|
||||
install -d -m755 $RPM_BUILD_ROOT/etc/smrsh
|
||||
|
||||
cat <<EOF > $RPM_BUILD_ROOT/etc/mail/access
|
||||
@ -284,13 +254,12 @@ localhost RELAY
|
||||
127.0.0.1 RELAY
|
||||
|
||||
EOF
|
||||
for map in virtusertable access domaintable mailertable
|
||||
do
|
||||
for map in virtusertable access domaintable mailertable ; do
|
||||
touch $RPM_BUILD_ROOT/etc/mail/${map}
|
||||
chmod 0644 $RPM_BUILD_ROOT/etc/mail/${map}
|
||||
$RPM_BUILD_ROOT%{_bindir}/makemap -C $RPM_BUILD_ROOT/etc/mail/sendmail.cf hash $RPM_BUILD_ROOT/etc/mail/${map}.db < $RPM_BUILD_ROOT/etc/mail/${map}
|
||||
chmod 0644 $RPM_BUILD_ROOT/etc/mail/${map}.db
|
||||
done
|
||||
done
|
||||
install -m644 %{SOURCE3} $RPM_BUILD_ROOT/etc/aliases
|
||||
$RPM_BUILD_ROOT/usr/bin/makemap -C $RPM_BUILD_ROOT/etc/mail/sendmail.cf hash $RPM_BUILD_ROOT/etc/aliases.db < %{SOURCE3}
|
||||
|
||||
@ -302,9 +271,6 @@ install -m 644 %{SOURCE5} $RPM_BUILD_ROOT/etc/mail/Makefile
|
||||
chmod u+w $RPM_BUILD_ROOT/usr/sbin/{mailstats,praliases}
|
||||
chmod u+w $RPM_BUILD_ROOT/usr/bin/rmail
|
||||
|
||||
# strip $RPM_BUILD_ROOT/usr/sbin/{mailstats,praliases,sendmail}
|
||||
# strip $RPM_BUILD_ROOT/usr/bin/rmail
|
||||
|
||||
%if %{errata} > 62
|
||||
install -m755 -d $RPM_BUILD_ROOT%{_libdir}/sasl
|
||||
install -m 644 %{SOURCE7} $RPM_BUILD_ROOT%{_libdir}/sasl/Sendmail.conf
|
||||
@ -428,12 +394,12 @@ exit 0
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
/usr/sbin/mailstats
|
||||
/usr/sbin/praliases
|
||||
/usr/bin/hoststat
|
||||
/usr/bin/purgestat
|
||||
/usr/bin/makemap
|
||||
/usr/bin/purgestat
|
||||
/usr/sbin/mailstats
|
||||
/usr/sbin/makemap
|
||||
/usr/sbin/praliases
|
||||
%if %{errata} > 72
|
||||
%attr(2755,root,smmsp)/usr/sbin/sendmail.sendmail
|
||||
/usr/bin/rmail.sendmail
|
||||
@ -518,8 +484,9 @@ exit 0
|
||||
%{_docdir}/sendmail
|
||||
|
||||
%changelog
|
||||
* Tue Aug 27 2002 Nalin Dahyabhai <nalin@redhat.com>
|
||||
- rebuild
|
||||
* Thu Aug 29 2002 Florian La Roche <Florian.LaRoche@redhat.de>
|
||||
- clean up some specfile cruft
|
||||
- add more pseudo accounts to /etc/aliases
|
||||
|
||||
* Thu Jul 25 2002 Phil Knirsch <pknirsch@redhat.com>
|
||||
- Only generate new cf files if the /usr/share/sendmail-cf/m4/cf.m4 exists.
|
||||
|
Loading…
Reference in New Issue
Block a user