- fix #168866, use install -p to install documentation
This commit is contained in:
parent
bd7638a3f5
commit
f79562347c
@ -1 +1,2 @@
|
|||||||
dovecot-0.99.14.tar.gz
|
dovecot-0.99.14.tar.gz
|
||||||
|
dovecot-1.0.beta2.tar.gz
|
||||||
|
@ -1,14 +1,26 @@
|
|||||||
--- dovecot-0.99.13/dovecot-example.conf 2004-12-29 13:00:24.000000000 -0500
|
--- dovecot-1.0.beta2/doc/mkcert.sh.configfile 2006-01-16 21:14:54.000000000 +0100
|
||||||
+++ dovecot-0.99.13/dovecot.conf 2005-01-17 11:49:56.000000000 -0500
|
+++ dovecot-1.0.beta2/doc/mkcert.sh 2006-01-26 14:28:38.000000000 +0100
|
||||||
@@ -1,30 +1,24 @@
|
@@ -29,6 +29,7 @@
|
||||||
## Dovecot 1.0 configuration file
|
fi
|
||||||
|
|
||||||
-# Default values are shown after each value, it's not required to uncomment
|
$OPENSSL req -new -x509 -nodes -config $OPENSSLCONFIG -out $CERTFILE -keyout $KEYFILE -days 365 || exit 2
|
||||||
|
-chmod 0600 $KEYFILE
|
||||||
|
+chown root:root $CERTFILE $KEYFILE
|
||||||
|
+chmod 0600 $CERTFILE $KEYFILE
|
||||||
|
echo
|
||||||
|
$OPENSSL x509 -subject -fingerprint -noout -in $CERTFILE || exit 2
|
||||||
|
--- dovecot-1.0.beta2/dovecot-example.conf.configfile 2006-01-22 12:32:52.000000000 +0100
|
||||||
|
+++ dovecot-1.0.beta2/dovecot-example.conf 2006-01-26 14:31:23.000000000 +0100
|
||||||
|
@@ -5,17 +5,14 @@
|
||||||
|
# value inside quotes, eg.: key = "# char and trailing whitespace "
|
||||||
|
|
||||||
|
# Default values are shown after each value, it's not required to uncomment
|
||||||
-# any of the lines. Exception to this are paths, they're just examples
|
-# any of the lines. Exception to this are paths, they're just examples
|
||||||
-# with real defaults being based on configure options. The paths listed here
|
-# with real defaults being based on configure options. The paths listed here
|
||||||
-# are for configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
|
-# are for configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
|
||||||
-# --with-ssldir=/etc/ssl
|
-# --with-ssldir=/etc/ssl
|
||||||
-
|
+# any of the lines.
|
||||||
|
|
||||||
# Base directory where to store runtime data.
|
# Base directory where to store runtime data.
|
||||||
#base_dir = /var/run/dovecot/
|
#base_dir = /var/run/dovecot/
|
||||||
|
|
||||||
@ -19,78 +31,39 @@
|
|||||||
|
|
||||||
# IP or host address where to listen in for connections. It's not currently
|
# IP or host address where to listen in for connections. It's not currently
|
||||||
# possible to specify multiple addresses. "*" listens in all IPv4 interfaces.
|
# possible to specify multiple addresses. "*" listens in all IPv4 interfaces.
|
||||||
# "[::]" listens in all IPv6 interfaces, but may also listen in all IPv4
|
@@ -24,11 +21,11 @@
|
||||||
# interfaces depending on the operating system. You can specify ports with
|
# for each service, you will need to configure these settings inside the
|
||||||
# "host:port".
|
# protocol imap/pop3 { ... } section, so you can specify different ports
|
||||||
-#imap_listen = *
|
# for IMAP/POP3.
|
||||||
-#pop3_listen = *
|
-#listen = *
|
||||||
+imap_listen = [::]
|
+listen = [::]
|
||||||
+pop3_listen = [::]
|
|
||||||
|
|
||||||
# IP or host address where to listen in for SSL connections. Defaults
|
# IP or host address where to listen in for SSL connections. Defaults
|
||||||
# to above non-SSL equilevants if not specified.
|
# to above if not specified.
|
||||||
-#imaps_listen =
|
-#ssl_listen =
|
||||||
-#pop3s_listen =
|
+ssl_listen = [::]
|
||||||
+imaps_listen = [::]
|
|
||||||
+pop3s_listen = [::]
|
|
||||||
|
|
||||||
# Disable SSL/TLS support.
|
# Disable SSL/TLS support.
|
||||||
#ssl_disable = no
|
#ssl_disable = no
|
||||||
@@ -33,8 +27,8 @@
|
@@ -37,8 +34,8 @@
|
||||||
# dropping root privileges, so keep the key file unreadable by anyone but
|
# dropping root privileges, so keep the key file unreadable by anyone but
|
||||||
# root. Included doc/mkcert.sh can be used to easily generate self-signed
|
# root. Included doc/mkcert.sh can be used to easily generate self-signed
|
||||||
# certificate, just make sure to update the domains in dovecot-openssl.cnf
|
# certificate, just make sure to update the domains in dovecot-openssl.cnf
|
||||||
-#ssl_cert_file = /etc/ssl/certs/dovecot.pem
|
-#ssl_cert_file = /etc/ssl/certs/dovecot.pem
|
||||||
-#ssl_key_file = /etc/ssl/private/dovecot.pem
|
-#ssl_key_file = /etc/ssl/private/dovecot.pem
|
||||||
+ssl_cert_file = /etc/pki/dovecot/dovecot.pem
|
+ssl_cert_file = /etc/pki/dovecot/certs/dovecot.pem
|
||||||
+ssl_key_file = /etc/pki/dovecot/private/dovecot.pem
|
+ssl_key_file = /etc/pki/dovecot/private/dovecot.pem
|
||||||
|
|
||||||
# SSL parameter file. Master process generates this file for login processes.
|
# If key file is password protected, give the password here. Alternatively
|
||||||
# It contains Diffie Hellman and RSA parameters.
|
# give it when starting dovecot with -p parameter.
|
||||||
@@ -70,7 +64,7 @@
|
@@ -351,8 +348,8 @@
|
||||||
# which login needs to be able to connect to. The sockets are created when
|
# in is important to avoid deadlocks if other MTAs/MUAs are using multiple
|
||||||
# running as root, so you don't have to worry about permissions. Note that
|
# locking methods as well. Some operating systems don't allow using some of
|
||||||
# everything in this directory is deleted when Dovecot is started.
|
# them simultaneously.
|
||||||
-#login_dir = /var/run/dovecot/login
|
-#mbox_read_locks = fcntl
|
||||||
+login_dir = /var/run/dovecot-login
|
-#mbox_write_locks = dotlock fcntl
|
||||||
|
+mbox_read_locks = fcntl
|
||||||
|
+mbox_write_locks = fcntl
|
||||||
|
|
||||||
# chroot login process to the login_dir. Only reason not to do this is if you
|
# Maximum time in seconds to wait for lock (all of them) before aborting.
|
||||||
# wish to run the whole Dovecot without roots.
|
#mbox_lock_timeout = 300
|
||||||
@@ -308,7 +302,7 @@
|
|
||||||
# with is important to avoid deadlocks if other MTAs/MUAs are using both fcntl
|
|
||||||
# and flock. Some operating systems don't allow using both of them
|
|
||||||
# simultaneously, eg. BSDs. If dotlock is used, it's always created first.
|
|
||||||
-#mbox_locks = dotlock fcntl
|
|
||||||
+mbox_locks = fcntl
|
|
||||||
|
|
||||||
# Should we create dotlock file even when we want only a read-lock? Setting
|
|
||||||
# this to yes hurts the performance when the mailbox is accessed simultaneously
|
|
||||||
diff -u -r dovecot-0.99.11.orig/doc/mkcert.sh dovecot-0.99.11/doc/mkcert.sh
|
|
||||||
--- dovecot-0.99.11.orig/doc/mkcert.sh 2004-07-22 20:04:37.000000000 -0400
|
|
||||||
+++ dovecot-0.99.11/doc/mkcert.sh 2004-12-22 16:33:20.000000000 -0500
|
|
||||||
@@ -4,11 +4,12 @@
|
|
||||||
# Edit dovecot-openssl.cnf before running this.
|
|
||||||
|
|
||||||
OPENSSL=${OPENSSL-openssl}
|
|
||||||
-SSLDIR=${SSLDIR-/etc/ssl}
|
|
||||||
-OPENSSLCONFIG=${OPENSSLCONFIG-dovecot-openssl.cnf}
|
|
||||||
+SSLDIR=${SSLDIR-/etc/pki/dovecot}
|
|
||||||
+OPENSSLCONFIG=${OPENSSLCONFIG-$SSLDIR/dovecot-openssl.cnf}
|
|
||||||
+CERTNAME=${CERTNAME-dovecot}
|
|
||||||
|
|
||||||
-CERTFILE=$SSLDIR/certs/imapd.pem
|
|
||||||
-KEYFILE=$SSLDIR/private/imapd.pem
|
|
||||||
+CERTFILE=$SSLDIR/$CERTNAME.pem
|
|
||||||
+KEYFILE=$SSLDIR/private/$CERTNAME.pem
|
|
||||||
|
|
||||||
if [ ! -d $SSLDIR/certs ]; then
|
|
||||||
echo "$SSLDIR/certs directory doesn't exist"
|
|
||||||
@@ -29,6 +30,7 @@
|
|
||||||
fi
|
|
||||||
|
|
||||||
$OPENSSL req -new -x509 -nodes -config $OPENSSLCONFIG -out $CERTFILE -keyout $KEYFILE -days 365 || exit 2
|
|
||||||
-chmod 0600 $KEYFILE
|
|
||||||
+chown root:root $CERTFILE $KEYFILE
|
|
||||||
+chmod 0600 $CERTFILE $KEYFILE
|
|
||||||
echo
|
|
||||||
$OPENSSL x509 -subject -fingerprint -noout -in $CERTFILE || exit 2
|
|
||||||
|
86
dovecot.spec
86
dovecot.spec
@ -1,14 +1,15 @@
|
|||||||
Summary: Dovecot Secure imap server
|
Summary: Dovecot Secure imap server
|
||||||
Name: dovecot
|
Name: dovecot
|
||||||
Version: 0.99.14
|
Version: 1.0
|
||||||
Release: 10.fc5.1
|
Release: 0.beta2
|
||||||
License: LGPL
|
License: LGPL
|
||||||
Group: System Environment/Daemons
|
Group: System Environment/Daemons
|
||||||
|
|
||||||
%define build_postgres 1
|
%define build_postgres 1
|
||||||
%define build_mysql 1
|
%define build_mysql 1
|
||||||
|
%define upstream 1.0.beta2
|
||||||
|
|
||||||
Source: %{name}-%{version}.tar.gz
|
Source: %{name}-1.0.beta2.tar.gz
|
||||||
Source1: dovecot.init
|
Source1: dovecot.init
|
||||||
Source2: dovecot.pam
|
Source2: dovecot.pam
|
||||||
Source3: maildir-migration.txt
|
Source3: maildir-migration.txt
|
||||||
@ -43,7 +44,7 @@ BuildRequires: postgresql-devel
|
|||||||
BuildRequires: mysql-devel
|
BuildRequires: mysql-devel
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%define docdir %{_docdir}/%{name}-%{version}
|
%define docdir %{_docdir}/%{name}
|
||||||
%define ssldir /etc/pki/%{name}
|
%define ssldir /etc/pki/%{name}
|
||||||
%define restart_flag /var/run/%{name}-restart-after-rpm-install
|
%define restart_flag /var/run/%{name}-restart-after-rpm-install
|
||||||
%define dovecot_uid 97
|
%define dovecot_uid 97
|
||||||
@ -56,14 +57,14 @@ in either of maildir or mbox formats.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
|
|
||||||
%setup -q -n %{name}-%{version}
|
%setup -q -n %{name}-%{upstream}
|
||||||
|
|
||||||
%patch100 -p1 -b .config
|
#%patch100 -p1 -b .config
|
||||||
cp $RPM_BUILD_DIR/${RPM_PACKAGE_NAME}-${RPM_PACKAGE_VERSION}/dovecot-example.conf $RPM_BUILD_DIR/${RPM_PACKAGE_NAME}-${RPM_PACKAGE_VERSION}/dovecot.conf
|
#cp $RPM_BUILD_DIR/dovecot-%{upstream}/dovecot-example.conf $RPM_BUILD_DIR/${RPM_PACKAGE_NAME}-%{upstream}/dovecot.conf
|
||||||
%patch101 -p1 -b .configfile
|
%patch101 -p1 -b .configfile
|
||||||
%patch102 -p1 -b .no-literal-plus-capability
|
#%patch102 -p1 -b .no-literal-plus-capability
|
||||||
%patch103 -p1 -b .pam-setcred
|
#%patch103 -p1 -b .pam-setcred
|
||||||
%patch104 -p1 -b .auth-log
|
#%patch104 -p1 -b .auth-log
|
||||||
|
|
||||||
%build
|
%build
|
||||||
rm -f ./configure
|
rm -f ./configure
|
||||||
@ -71,7 +72,8 @@ aclocal
|
|||||||
automake -a
|
automake -a
|
||||||
autoconf
|
autoconf
|
||||||
%configure \
|
%configure \
|
||||||
--with-docdir=%{docdir} \
|
INSTALL_DATA="install -c -p -m644" \
|
||||||
|
--with-doc \
|
||||||
%if %{build_postgres}
|
%if %{build_postgres}
|
||||||
--with-pgsql \
|
--with-pgsql \
|
||||||
%endif
|
%endif
|
||||||
@ -95,25 +97,37 @@ mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/pam.d
|
|||||||
install -m 644 %{SOURCE2} $RPM_BUILD_ROOT/%{_sysconfdir}/pam.d/dovecot
|
install -m 644 %{SOURCE2} $RPM_BUILD_ROOT/%{_sysconfdir}/pam.d/dovecot
|
||||||
|
|
||||||
# generate ghost .pem file
|
# generate ghost .pem file
|
||||||
|
mkdir -p $RPM_BUILD_ROOT/%{ssldir}/certs
|
||||||
mkdir -p $RPM_BUILD_ROOT/%{ssldir}/private
|
mkdir -p $RPM_BUILD_ROOT/%{ssldir}/private
|
||||||
touch $RPM_BUILD_ROOT/%{ssldir}/dovecot.pem
|
touch $RPM_BUILD_ROOT/%{ssldir}/certs/dovecot.pem
|
||||||
chmod 600 $RPM_BUILD_ROOT/%{ssldir}/dovecot.pem
|
chmod 600 $RPM_BUILD_ROOT/%{ssldir}/certs/dovecot.pem
|
||||||
touch $RPM_BUILD_ROOT/%{ssldir}/private/dovecot.pem
|
touch $RPM_BUILD_ROOT/%{ssldir}/private/dovecot.pem
|
||||||
chmod 600 $RPM_BUILD_ROOT/%{ssldir}/private/dovecot.pem
|
chmod 600 $RPM_BUILD_ROOT/%{ssldir}/private/dovecot.pem
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/var/run/dovecot
|
mkdir -p $RPM_BUILD_ROOT/var/run/dovecot/login
|
||||||
chmod 700 $RPM_BUILD_ROOT/var/run/dovecot
|
chmod 755 $RPM_BUILD_ROOT/var/run/dovecot
|
||||||
mkdir -p $RPM_BUILD_ROOT/var/run/dovecot-login
|
chmod 700 $RPM_BUILD_ROOT/var/run/dovecot/login
|
||||||
|
|
||||||
|
# Install dovecot.conf and dovecot-openssl.cnf
|
||||||
|
mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/pki/dovecot/
|
||||||
|
install -p -m644 $RPM_SOURCE_DIR/dovecot-%{upstream}/dovecot-example.conf $RPM_BUILD_ROOT/%{_sysconfdir}/dovecot.conf
|
||||||
|
rm -f $RPM_BUILD_ROOT/%{_sysconfdir}/dovecot-example.conf # dovecot seems to install this by itself
|
||||||
|
install -p -m644 $RPM_SOURCE_DIR/dovecot-%{upstream}/doc/dovecot-openssl.cnf $RPM_BUILD_ROOT/%{_sysconfdir}/pki/dovecot/dovecot-openssl.cnf
|
||||||
|
|
||||||
# Install some of our own documentation
|
# Install some of our own documentation
|
||||||
install -m644 $RPM_SOURCE_DIR/dovecot-REDHAT-FAQ.txt $RPM_BUILD_ROOT%{docdir}/REDHAT-FAQ.txt
|
install -p -m644 $RPM_SOURCE_DIR/dovecot-REDHAT-FAQ.txt $RPM_BUILD_ROOT%{docdir}/REDHAT-FAQ.txt
|
||||||
|
|
||||||
install -m755 -d $RPM_BUILD_ROOT%{docdir}/UW-to-Dovecot-Migration
|
mkdir -p $RPM_BUILD_ROOT%{docdir}/examples/
|
||||||
|
install -p -m755 $RPM_SOURCE_DIR/dovecot-%{upstream}/doc/mkcert.sh $RPM_BUILD_ROOT%{docdir}/examples/mkcert.sh
|
||||||
|
|
||||||
|
install -p -m755 -d $RPM_BUILD_ROOT%{docdir}/UW-to-Dovecot-Migration
|
||||||
for f in maildir-migration.txt migrate-folders migrate-users perfect_maildir.pl
|
for f in maildir-migration.txt migrate-folders migrate-users perfect_maildir.pl
|
||||||
do
|
do
|
||||||
install -m644 $RPM_SOURCE_DIR/$f $RPM_BUILD_ROOT%{docdir}/UW-to-Dovecot-Migration
|
install -p -m644 $RPM_SOURCE_DIR/$f $RPM_BUILD_ROOT%{docdir}/UW-to-Dovecot-Migration
|
||||||
done
|
done
|
||||||
|
|
||||||
|
mv $RPM_BUILD_ROOT%{docdir} $RPM_BUILD_ROOT%{docdir}-%{version}
|
||||||
|
|
||||||
%pre
|
%pre
|
||||||
/usr/sbin/useradd -c "dovecot" -u %{dovecot_uid} -s /sbin/nologin -r -d /usr/libexec/dovecot dovecot 2>/dev/null || :
|
/usr/sbin/useradd -c "dovecot" -u %{dovecot_uid} -s /sbin/nologin -r -d /usr/libexec/dovecot dovecot 2>/dev/null || :
|
||||||
|
|
||||||
@ -128,13 +142,17 @@ fi
|
|||||||
%post
|
%post
|
||||||
/sbin/chkconfig --add %{name}
|
/sbin/chkconfig --add %{name}
|
||||||
# create a ssl cert
|
# create a ssl cert
|
||||||
if [ -f /usr/share/ssl/certs/dovecot.pem -a ! -f %{ssldir}/%{name}.pem ]; then
|
if [ -f %{ssldir}/%{name}.pem -a ! -f %{ssldir}/certs/%{name}.pem ]; then
|
||||||
mv /usr/share/ssl/certs/dovecot.pem %{ssldir}/%{name}.pem
|
mv %{ssldir}/%{name}.pem %{ssldir}/certs/%{name}.pem
|
||||||
|
else
|
||||||
|
if [ -f /usr/share/ssl/certs/dovecot.pem -a ! -f %{ssldir}/certs/%{name}.pem ]; then
|
||||||
|
mv /usr/share/ssl/certs/dovecot.pem %{ssldir}/certs/%{name}.pem
|
||||||
|
fi
|
||||||
|
if [ -f /usr/share/ssl/private/dovecot.pem -a ! -f %{ssldir}/private/%{name}.pem ]; then
|
||||||
|
mv /usr/share/ssl/private/dovecot.pem %{ssldir}/private/%{name}.pem
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
if [ -f /usr/share/ssl/private/dovecot.pem -a ! -f %{ssldir}/private/%{name}.pem ]; then
|
if [ ! -f %{ssldir}/certs/%{name}.pem ]; then
|
||||||
mv /usr/share/ssl/private/dovecot.pem %{ssldir}/private/%{name}.pem
|
|
||||||
fi
|
|
||||||
if [ ! -f %{ssldir}/%{name}.pem ]; then
|
|
||||||
%{docdir}/examples/mkcert.sh &> /dev/null
|
%{docdir}/examples/mkcert.sh &> /dev/null
|
||||||
fi
|
fi
|
||||||
# Restart if it had been running before installation
|
# Restart if it had been running before installation
|
||||||
@ -158,22 +176,30 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%doc %{docdir}
|
%doc %{docdir}-%{version}
|
||||||
%config(noreplace) %{_sysconfdir}/dovecot.conf
|
%config(noreplace) %{_sysconfdir}/dovecot.conf
|
||||||
%config %{_sysconfdir}/rc.d/init.d/dovecot
|
%config %{_sysconfdir}/rc.d/init.d/dovecot
|
||||||
%config %{_sysconfdir}/pam.d/dovecot
|
%config %{_sysconfdir}/pam.d/dovecot
|
||||||
%config(noreplace) %{ssldir}/dovecot-openssl.cnf
|
%config(noreplace) %{ssldir}/dovecot-openssl.cnf
|
||||||
%attr(0600,root,root) %ghost %config(missingok,noreplace) %verify(not md5 size mtime) %{ssldir}/dovecot.pem
|
%attr(0600,root,root) %ghost %config(missingok,noreplace) %verify(not md5 size mtime) %{ssldir}/certs/dovecot.pem
|
||||||
%attr(0600,root,root) %ghost %config(missingok,noreplace) %verify(not md5 size mtime) %{ssldir}/private/dovecot.pem
|
%attr(0600,root,root) %ghost %config(missingok,noreplace) %verify(not md5 size mtime) %{ssldir}/private/dovecot.pem
|
||||||
%dir %{_libexecdir}/%{name}
|
%dir %{_libexecdir}/%{name}
|
||||||
%{_libexecdir}/%{name}/*
|
%{_libexecdir}/%{name}/*
|
||||||
|
%{_libdir}/%{name}/imap/*
|
||||||
|
%{_libdir}/%{name}/lda/*
|
||||||
|
%{_libdir}/%{name}/*
|
||||||
%{_sbindir}/dovecot
|
%{_sbindir}/dovecot
|
||||||
%dir /var/run/dovecot
|
%{_sbindir}/dovecotpw
|
||||||
%attr(0750,root,dovecot) %dir /var/run/dovecot-login
|
%attr(0755,root,dovecot) %dir /var/run/dovecot
|
||||||
%attr(0750,root,dovecot) %{docdir}/examples/mkcert.sh
|
%attr(0750,root,dovecot) %dir /var/run/dovecot/login
|
||||||
|
%attr(0750,root,dovecot) %{docdir}-%{version}/examples/mkcert.sh
|
||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Jan 23 2006 Petr Rockai <prockai@redhat.com> - 1.0-0.beta2
|
||||||
|
- new upstream version, hopefully fixes #173928, #163550
|
||||||
|
- fix #168866, use install -p to install documentation
|
||||||
|
|
||||||
* Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com>
|
* Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com>
|
||||||
- rebuilt
|
- rebuilt
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user