X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=courier.spec;h=dfa1ec01727de5cd6be40803b069281ace2869b4;hb=3b73318a0854c5fb2a9e75cc3dc0f19bb04c36f4;hp=66234c2730eab4f7f4533726db38e388fecedf68;hpb=3af679c50a51d4c7b89dd79802fd7170a876ec70;p=packages%2Fcourier.git diff --git a/courier.spec b/courier.spec index 66234c2..dfa1ec0 100644 --- a/courier.spec +++ b/courier.spec @@ -1,22 +1,63 @@ +# +# Conditional build: +%bcond_with fam # with fam support +# Summary: Courier mail server Summary(pl): Serwer poczty Courier Name: courier -Version: 0.35.1 -Release: 2 +Version: 0.45.2 +Release: 1 License: GPL -Group: Applications/Mail -Group(de): Applikationen/Post -Group(pl): Aplikacje/Poczta -Group(pt): Aplicações/Correio Eletrônico -Source0: http://ftp1.sourceforge.net/courier/%{name}-%{version}.tar.gz +Group: Networking/Daemons +Source0: http://dl.sourceforge.net/courier/%{name}-%{version}.tar.bz2 +# Source0-md5: 6242d984744e1969db970ea798ecd564 +Patch0: %{name}-openssl-path.patch +Patch1: %{name}-withoutfam.patch +Patch2: %{name}-maildir.patch +Patch3: %{name}-sendmail_dir.patch +Patch4: %{name}-start_scripts.patch URL: http://www.courier-mta.org/ -BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: db-devel +BuildRequires: expect +BuildRequires: libstdc++-devel +BuildRequires: libtool +BuildRequires: mailcap +BuildRequires: mysql-devel +BuildRequires: openldap-devel +BuildRequires: openssl-devel >= 0.9.7d +BuildRequires: openssl-tools >= 0.9.7d +BuildRequires: openssl-tools-perl >= 0.9.7d +BuildRequires: pam-devel +BuildRequires: perl-devel +BuildRequires: postgresql-devel +BuildRequires: sysconftool +BuildRequires: zlib-devel +%{?with_fam:BuildRequires: fam-devel} +Requires(post,preun): /sbin/chkconfig +Requires(post): openssl-tools >= 0.9.7d +%{?with_fam:Requires: fam} Provides: smtpdaemon -#AutoProv: no -Prereq: /sbin/chkconfig +Obsoletes: exim +Obsoletes: masqmail +Obsoletes: nullmailer +Obsoletes: omta +Obsoletes: qmail +Obsoletes: sendmail +Obsoletes: sendmail-cf +Obsoletes: sendmail-doc +Obsoletes: smail +Obsoletes: smtpdaemon +Obsoletes: ssmtp +Obsoletes: zmailer +BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) -%define apachedir /home/httpd -%define _prefix /usr/lib/courier +%define apachedir /home/services/httpd +%define _datadir %{_prefix}/share/courier +%define _mandir /usr/share/man +%define _libdir %{_prefix}/%{_lib}/courier +%define _libexecdir %{_libdir} %define _localstatedir /var/spool/courier %define _sysconfdir /etc/courier %define initdir /etc/rc.d/init.d @@ -51,34 +92,12 @@ Courier zawiera wiele rozszerze tak¿e nowe rozszerzenia SMTP dla pocztowych list dyskusyjnych i filtrowania spamu. -%package sendmail-wrapper -Summary: Courier soft links for sendmail -Summary(pl): Wrapper sendmail do Couriera -Group: Applications/Mail -Group(de): Applikationen/Post -Group(pl): Aplikacje/Poczta -Group(pt): Aplicações/Correio Eletrônico -Requires: %{name} = %{version} - -%description sendmail-wrapper -This package contains two soft links from /usr/sbin/sendmail and -/usr/lib/sendmail to %{_bindir}/sendmail. This allows application that -use sendmail to transparently use Courier for sending mail. - -%description sendmail-wrapper -l pl -# acc. FHS these symlinks should be in main package... -Ten pakiet zawiera symlinki z /usr/sbin/sendmail i /usr/lib/sendmail -do %{_bindir}/sendmail. Pozwala to aplikacjom u¿ywaj±cym sendmaila -korzystaæ z Couriera. - %package pop3d Summary: Courier Integrated POP3 server Summary(pl): Zintegrowany serwer POP3 do Couriera -Group: Applications/Mail -Group(de): Applikationen/Post -Group(pl): Aplikacje/Poczta -Group(pt): Aplicações/Correio Eletrônico -Requires: %{name} = %{version} +Group: Networking/Daemons +Requires: %{name} = %{version}-%{release} +Requires(post): openssl-tools >= 0.9.7d %description pop3d This package installs Courier mail server's integrated POP3 server, @@ -97,11 +116,9 @@ obs %package imapd Summary: Courier Integrated IMAP server Summary(pl): Zintegrowany serwer IMAP do Couriera -Group: Applications/Mail -Group(de): Applikationen/Post -Group(pl): Aplikacje/Poczta -Group(pt): Aplicações/Correio Eletrônico -Requires: %{name} = %{version} +Group: Networking/Daemons +Requires: %{name} = %{version}-%{release} +Requires(post): openssl-tools >= 0.9.7d Obsoletes: courier-imap Obsoletes: courier-imap-common @@ -133,11 +150,8 @@ pakietu automatycznie odinstaluje Courier-IMAP je %package webmail Summary: Courier Integrated HTTP (webmail) server Summary(pl): Zintegrowany serwer poczty przez HTTP (webmail) do Couriera -Group: Applications/Mail -Group(de): Applikationen/Post -Group(pl): Aplikacje/Poczta -Group(pt): Aplicações/Correio Eletrônico -Requires: %{name} = %{version} +Group: Networking/Daemons +Requires: %{name} = %{version}-%{release} Requires: %{_cgibindir} Requires: %{_documentrootdir} @@ -163,12 +177,9 @@ SqWebMail, ale jego konfiguracja jest dostosowana do serwera Courier. %package mlm Summary: Courier Integrated Mailing List Manager -Summary(pl): Zintegrowany menad¿er list dyskusyjnych do Couriera +Summary(pl): Zintegrowany zarz±dca list dyskusyjnych do Couriera Group: Applications/Mail -Group(de): Applikationen/Post -Group(pl): Aplikacje/Poczta -Group(pt): Aplicações/Correio Eletrônico -Requires: %{name} = %{version} +Requires: %{name} = %{version}-%{release} %description mlm This package installs couriermlm - a mailing list manager for the @@ -183,22 +194,19 @@ administrative oversight. couriermlm supports digests, write-only posting aliases, and moderated mailing lists. %description mlm -l pl -Ten pakiet zawiera couriermlm - menad¿er list dyskusyjnych dla -Couriera. couriermlm jest u¿ywany do skonfigurowania, zarz±dzania i -prowadzenia pocztowej listy dyskusyjnej. Automatycznie obs³uguje -¿±dania zapisywania i wypisywania i usuwa niedzia³aj±ce adresy z listy -subskrybentów. Listy obs³ugiwane przez couriermlm nie wymagaj± pracy -administratora. couriermlm obs³uguje digesty, aliasy pocztowe tylko do -wysy³ania i listy moderowane. +Ten pakiet zawiera couriermlm - program do zarz±dzania listami +dyskusyjnymi dla Couriera. couriermlm jest u¿ywany do konfigurowania, +zarz±dzania i prowadzenia pocztowej listy dyskusyjnej. Automatycznie +obs³uguje ¿±dania zapisywania i wypisywania oraz usuwa z listy +niedzia³aj±ce adresy subskrybentów. Listy obs³ugiwane przez couriermlm +nie wymagaj± pracy administratora. couriermlm obs³uguje digesty, +aliasy pocztowe tylko do wysy³ania i listy moderowane. %package maildrop Summary: Courier Integrated mail filter Summary(pl): Zintegrowany filtr poczty do Couriera Group: Applications/Mail -Group(de): Applikationen/Post -Group(pl): Aplikacje/Poczta -Group(pt): Aplicações/Correio Eletrônico -Requires: %{name} = %{version} +Requires: %{name} = %{version}-%{release} %description maildrop This package installs Courier mail server's integrated mail filter. @@ -209,219 +217,227 @@ incoming mail. Ten pakiet zawiera zintegrowany filtr poczty dla Couriera. Jest potrzebny do filtrowania przychodz±cej poczty. -%package maildrop-wrapper -Summary: Courier soft links for maildrop -Summary(pl): Wrapper maildrop do Couriera -Group: Applications/Mail -Group(de): Applikationen/Post -Group(pl): Aplikacje/Poczta -Group(pt): Aplicações/Correio Eletrônico -Requires: %{name}-maildrop = %{version} - -%description maildrop-wrapper -This package installs several soft links from the /usr/local/bin -directory to Courier's integrated maildrop mail filter. Maildrop is -available as a standalone package, which installs in %{_bindir}. If -you have applications that expect to find maildrop in /usr/local/bin -you can install this package to create soft links that point to -Courier's integrated maildrop version instead, in order to continue to -use those applications, without needing to reconfigure them. - -%description maildrop-wrapper -l pl -# hmmm ??? to be removed... -Ten pakiet zawiera symlinki z katalogu /usr/local/bin do filtru -maildrop Couriera. maildrop jest dostêpnym w oddzielnym pakiecie, -instaluj±cym siê w %{_bindir}. Przydaje siê aplikacjom szukaj±cym -maildropa w /usr/local/bin do u¿ywania z Courierem bez -rekonfigurowania. - %package smtpauth Summary: Courier mail server authenticated ESMTP module -Summary(pl): Modu³ autentykacji ESMTP (SMTP AUTH) do Couriera -Group: Applications/Mail -Group(de): Applikationen/Post -Group(pl): Aplikacje/Poczta -Group(pt): Aplicações/Correio Eletrônico -Requires: %{name} = %{version} +Summary(pl): Modu³ uwierzytelniania ESMTP (SMTP AUTH) do Couriera +Group: Networking/Daemons +Requires: %{name} = %{version}-%{release} %description smtpauth Authenticated ESMTP allows remote users to authenticate themselves and be able to relay outbound mail through the Courier mail server. %description smtpauth -l pl -SMTP AUTH pozwala zdalnym u¿ytkownikom na autentykacjê i umo¿liwienie -przekazania wychodz±cej poczty poprzez serwer poczty Courier. +SMTP AUTH pozwala zdalnym u¿ytkownikom na uwierzytelnianie i +umo¿liwienie przekazania wychodz±cej poczty poprzez serwer poczty +Courier. -%prep -%setup -q +%package authldap +Summary: LDAP authentication daemon for Courier mail server +Summary(pl): Demon autentykacji LDAP do Couriera +Group: Networking/Daemons +PreReq: %{name} = %{version}-%{release} -%configure2_13 \ - --localstatedir=%{_localstatedir} \ - --sysconfdir=%{_sysconfdir} \ - --mandir=%{_mandir} \ - --enable-imageurl=%{_imageurl} +%description authldap +This package provides LDAP authentication for Courier. -cat >README.REDHAT < $RPM_BUILD_ROOT/etc/pam.d/$X <>permissions.dat -echo '/etc/profile.d/courier.sh 755 bin bin config' >>permissions.dat -echo '/etc/profile.d/courier.csh 755 bin bin config' >>permissions.dat -echo '%{initdir}/courier 755 bin bin config' >>permissions.dat +# delete dead links +rm -f $RPM_BUILD_ROOT%{_mandir}/man1/dotforward.1 \ +$RPM_BUILD_ROOT%{_mandir}/man1/rmail.1 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authcram.7 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authdaemon.7 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authdaemond.7 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authldap.7 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authmysql.7 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authpam.7 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authpwd.7 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authshadow.7 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authuserdb.7 \ +$RPM_BUILD_ROOT%{_mandir}/man7/authvchkpw.7 \ +$RPM_BUILD_ROOT%{_mandir}/man8/esmtpd-msa.8 \ +$RPM_BUILD_ROOT%{_mandir}/man8/makesmtpaccess-msa.8 \ +$RPM_BUILD_ROOT%{_mandir}/man8/filterctl.8 \ +$RPM_BUILD_ROOT%{_mandir}/man8/makeuucpneighbors.8 \ +$RPM_BUILD_ROOT%{_mandir}/man8/pw2userdb.8 \ +$RPM_BUILD_ROOT%{_mandir}/man8/vchkpw2userdb.8 \ +$RPM_BUILD_ROOT%{_mandir}/man8/courierpop3login.8 + +# make man links +echo '.so dot-forward.1' > $RPM_BUILD_ROOT%{_mandir}/man1/dotforward.1 +echo '.so sendmail.1' > $RPM_BUILD_ROOT%{_mandir}/man1/rmail.1 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authcram.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authdaemon.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authdaemond.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authldap.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authmysql.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authpgsql.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authpam.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authpwd.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authshadow.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authuserdb.7 +echo '.so authlib.7' > $RPM_BUILD_ROOT%{_mandir}/man7/authvchkpw.7 +echo '.so esmtpd.8' > $RPM_BUILD_ROOT%{_mandir}/man8/esmtpd-msa.8 +echo '.so courierfilter.8' > $RPM_BUILD_ROOT%{_mandir}/man8/filterctl.8 +echo '.so makesmtpaccess.8' > $RPM_BUILD_ROOT%{_mandir}/man8/makesmtpaccess-msa.8 +echo '.so courieruucp.8' > $RPM_BUILD_ROOT%{_mandir}/man8/makeuucpneighbors.8 +echo '.so makeuserdb.8' > $RPM_BUILD_ROOT%{_mandir}/man8/pw2userdb.8 +echo '.so makeuserdb.8' > $RPM_BUILD_ROOT%{_mandir}/man8/vchkpw2userdb.8 +echo '.so courierpop3d.8' > $RPM_BUILD_ROOT%{_mandir}/man8/courierpop3login.8 -# -# Translate permissions.dat to spec file filelist. -# - -perl -e ' -$buildroot=$ENV{"RPM_BUILD_ROOT"}; -$prefix="%{_prefix}"; -$exec_prefix="%{_exec_prefix}"; - -while (<>) -{ - chop if /\n$/; - ($file,$mode,$uid,$gid,$special)=split(/ +/); - $file=$prefix if $file eq "$prefix/."; - - next if $special eq "doc"; - next if $file eq "$prefix/doc"; - - # Ignore dir/. entries - - next if $file =~ /\/\.$/; - - # Ignore man directories - - next if $file eq "%{_mandir}"; - next if substr($file, 0, length("%{_mandir}")) eq "%{_mandir}" - && substr($file, length("%{_mandir}")) =~ /^\/man[1-9]$/; - - $mode = "-" if $special eq "%doc"; - $special="%config" if $special eq "config"; - $special="%dir" if ! -l "$buildroot/$file" && -d "$buildroot/$file"; - if ($special eq "man") - { - if ( -l "$buildroot/$file" ) - { - print STDERR "ln -s " . readlink("$buildroot$file") - . ".gz $buildroot/$file.gz\n"; - symlink readlink("$buildroot$file") - . ".gz", "$buildroot/$file.gz"; - } - else - { - print STDERR "gzip <$buildroot$file >$buildroot$file.gz\n"; - system("gzip <$buildroot$file >$buildroot$file.gz ; rm -f $buildroot$file"); - } - $file="$file.gz" - } - $special="" unless $special =~ /%/; - - $special="%attr($mode, $uid, $gid) $special"; - print "$special $file\n"; -} - -' filelist1 || exit 1 - -sed -n '/imap[\.a-z0-9]*$/p;/imapd-ssl/p' filelist.imap -sed -n '/pop3[\.a-z0-9]*$/p' filelist.pop3 -sed -n '/couriermlm/p' filelist.mlm -sed -n '/authstart$/p;/authend$/p' filelist.auth -sed -n '/maildrop[^/]*$/p;/reformail[^/]*$/p;/reformime[^/]*$/p' filelist.maildrop -sed '/imap[\.a-z0-9]*$/d;/imapd-ssl/d;/pop3[\.a-z0-9]*$/d;/couriermlm/d;/webmail/d;/ldapaddressbook$/d;/maildrop[^/]*$/d;/reformail[^/]*$/d;/reformime[^/]*$/d;/authstart$/d;/authend$/d' filelist - -sed -n '/sqwebmail/p;/webmail.authpam/p;/webmail-logincache/p;/ldapaddressbook$/p' filelist.webmail +%{__make} install-perms # Note that we delete all 'webmail's, but copy over only 'sqwebmail's. # This removes all webmail-related stuff from the main filelist, # and adds everything except the executable, webmail, to filelist.webmail. # Here's why: -install -d $RPM_BUILD_ROOT%{_cgibindir} cp -f $RPM_BUILD_ROOT%{_libexecdir}/courier/webmail/webmail \ $RPM_BUILD_ROOT%{_cgibindir}/webmail # And here's why we delete all images from filelist.webmail: - -install -d $RPM_BUILD_ROOT%{_documentrootdir} mv -f $RPM_BUILD_ROOT%{_datadir}/sqwebmail/images $RPM_BUILD_ROOT%{_documentrootdir}/webmail -# Do we need to install a cron job to clean out webmail's cache? - -if test -f webmail/cron.cmd -then - install -d $RPM_BUILD_ROOT/etc/cron.hourly - cp webmail/cron.cmd $RPM_BUILD_ROOT/etc/cron.hourly/courier-webmail-cleancache - echo "%attr(555, root, wheel) /etc/cron.hourly/courier-webmail-cleancache" >>filelist.webmail -fi +# install a cron job to clean out webmail's cache +install webmail/cron.cmd $RPM_BUILD_ROOT/etc/cron.hourly/courier-webmail-cleancache -# # Move .html documentation back to build dir, so that RPM will move it to # the appropriate docdir -# rm -rf htmldoc mkdir htmldoc -cp -f $RPM_BUILD_ROOT%{_datadir}/htmldoc/* htmldoc +mv -f $RPM_BUILD_ROOT%{_datadir}/htmldoc/* htmldoc chmod a-w htmldoc/* # Manually set POP3DSTART and IMAPDSTART to yes, they'll go into a separate # package, so after it's installed they should be runnable. -sed 's/^POP3DSTART.*/POP3DSTART=YES/' <$RPM_BUILD_ROOT%{_sysconfdir}/pop3d >$RPM_BUILD_ROOT%{_sysconfdir}/pop3d.new -mv -f $RPM_BUILD_ROOT%{_sysconfdir}/pop3d.new $RPM_BUILD_ROOT%{_sysconfdir}/pop3d +sed 's/^POP3DSTART.*/POP3DSTART=YES/' <$RPM_BUILD_ROOT%{_sysconfdir}/pop3d.dist >$RPM_BUILD_ROOT%{_sysconfdir}/pop3d.new +mv -f $RPM_BUILD_ROOT%{_sysconfdir}/pop3d.new $RPM_BUILD_ROOT%{_sysconfdir}/pop3d.dist -sed 's/^IMAPDSTART.*/IMAPDSTART=YES/' <$RPM_BUILD_ROOT%{_sysconfdir}/imapd >$RPM_BUILD_ROOT%{_sysconfdir}/imapd.new -mv -f $RPM_BUILD_ROOT%{_sysconfdir}/imapd.new $RPM_BUILD_ROOT%{_sysconfdir}/imapd +sed 's/^POP3DSSLSTART.*/POP3DSSLSTART=YES/' <$RPM_BUILD_ROOT%{_sysconfdir}/pop3d-ssl.dist >$RPM_BUILD_ROOT%{_sysconfdir}/pop3d-ssl.new +mv -f $RPM_BUILD_ROOT%{_sysconfdir}/pop3d-ssl.new $RPM_BUILD_ROOT%{_sysconfdir}/pop3d-ssl.dist -sed 's/^IMAPDSSLSTART.*/IMAPDSSLSTART=YES/' <$RPM_BUILD_ROOT%{_sysconfdir}/imapd-ssl >$RPM_BUILD_ROOT%{_sysconfdir}/imapd.new-ssl -mv -f $RPM_BUILD_ROOT%{_sysconfdir}/imapd.new-ssl $RPM_BUILD_ROOT%{_sysconfdir}/imapd-ssl +sed 's/^IMAPDSTART.*/IMAPDSTART=YES/' <$RPM_BUILD_ROOT%{_sysconfdir}/imapd.dist >$RPM_BUILD_ROOT%{_sysconfdir}/imapd.new +mv -f $RPM_BUILD_ROOT%{_sysconfdir}/imapd.new $RPM_BUILD_ROOT%{_sysconfdir}/imapd.dist -# -# Red Hat init.d file -# +sed 's/^IMAPDSSLSTART.*/IMAPDSSLSTART=YES/' <$RPM_BUILD_ROOT%{_sysconfdir}/imapd-ssl.dist >$RPM_BUILD_ROOT%{_sysconfdir}/imapd.new-ssl +mv -f $RPM_BUILD_ROOT%{_sysconfdir}/imapd.new-ssl $RPM_BUILD_ROOT%{_sysconfdir}/imapd-ssl.dist + +# Want to have esmtpd running by default +sed 's/^ESMTPDSTART.*/ESMTPDSTART=YES/' <$RPM_BUILD_ROOT%{_sysconfdir}/esmtpd.dist >$RPM_BUILD_ROOT%{_sysconfdir}/esmtpd.new +mv -f $RPM_BUILD_ROOT%{_sysconfdir}/esmtpd.new $RPM_BUILD_ROOT%{_sysconfdir}/esmtpd.dist + +# run script from install-configure (make config files) +for confdist in `awk ' $5 == "config" && $1 ~ /\.dist$/ { print $1 }' $RPM_BUILD_ROOT%{_sysconfdir}/$X +done -cp -f courier.sysvinit $RPM_BUILD_ROOT%{initdir}/courier +install courier.sysvinit $RPM_BUILD_ROOT%{initdir}/courier # # Red Hat /etc/profile.d scripts @@ -458,130 +474,517 @@ else endif EOF -# # sendmail soft links -# - -install -d $RPM_BUILD_ROOT/usr/sbin -install -d $RPM_BUILD_ROOT/usr/lib -install -d $RPM_BUILD_ROOT/usr/bin - -ln -sf %{_bindir}/sendmail $RPM_BUILD_ROOT/usr/sbin/sendmail -ln -sf %{_bindir}/sendmail $RPM_BUILD_ROOT/usr/lib/sendmail -ln -sf %{_bindir}/sendmail $RPM_BUILD_ROOT/usr/bin/sendmail - -# -# maildrop wrapper soft links -# +ln -sf %{_sbindir}/sendmail $RPM_BUILD_ROOT/usr/lib/sendmail -install -d $RPM_BUILD_ROOT/usr/local/bin +# fix rmail link +rm -f $RPM_BUILD_ROOT%{_bindir}/rmail +ln -sf %{_sbindir}/sendmail $RPM_BUILD_ROOT%{_bindir}/rmail -for f in dotlock maildirmake maildrop makedat reformail reformime deliverquota -do - ln -s %{_bindir}/$f $RPM_BUILD_ROOT/usr/local/bin/$f -done +# This link by default is missing +ln -sf %{_datadir}/esmtpd-ssl $RPM_BUILD_ROOT%{_sbindir}/esmtpd-ssl -for f in makeuserdb pw2userdb userdb userdbpw vchkpw2userdb -do - ln -s %{_sbindir}/$f $RPM_BUILD_ROOT/usr/local/bin/$f -done - -# -# The following directories are not created by default, but I want them here. -# - -install -d $RPM_BUILD_ROOT%{_sysconfdir}/userdb -install -d $RPM_BUILD_ROOT%{_localstatedir}/tmp/broken - -. courier/uidgid || exit 1 - -mailuser=daemon -mailgroup=daemon - -echo "%attr(700, $mailuser, $mailgroup) %dir %{_sysconfdir}/userdb" >>filelist -echo "%attr(755, $mailuser, $mailgroup) %dir %{_localstatedir}/tmp/broken" >>filelist +# remove unpackaged files +rm -f $RPM_BUILD_ROOT%{_sysconfdir}/*.dist +rm -f $RPM_BUILD_ROOT%{_sysconfdir}/rfcerr*.txt +rm -rf $RPM_BUILD_ROOT%{_datadir}/faxmail %clean rm -rf $RPM_BUILD_ROOT %post +if [ "$1" = "1" ]; then /sbin/chkconfig --add courier -%{_sbindir}/makealiases 2>/dev/null || true -%{_sbindir}/makesmtpaccess 2>/dev/null || true -# If we do not have a certificate, make one up. +cat <