diff --git a/doc/man/Makefile.am b/doc/man/Makefile.am
index 0903722fd1294ba5ff7a5434a49c4df5cdd1539b..3868734b7f840dd121fffcc22ceeeb9738f3529a 100644
--- a/doc/man/Makefile.am
+++ b/doc/man/Makefile.am
@@ -1,3 +1,5 @@
+pkgsysconfdir = $(sysconfdir)/dovecot
+rundir = ${prefix}/var/run/dovecot
 unfinished = sieve-filter.1
 
 if BUILD_UNFINISHED
diff --git a/doc/man/sieve-filter.1.in b/doc/man/sieve-filter.1.in
index 0770fbcea2a01d4f3b18b4fa41b53660b9bcbde3..2d4cba9268ed3d33ccdb2269a3ea545fe9804212 100644
--- a/doc/man/sieve-filter.1.in
+++ b/doc/man/sieve-filter.1.in
@@ -207,10 +207,10 @@ Invalid parameter given. (EX_USAGE)
 .\"------------------------------------------------------------------------
 .SH FILES
 .TP
-.I /usr/local/etc/dovecot/dovecot.conf
+.I @pkgsysconfdir@/dovecot.conf
 Dovecot\(aqs main configuration file.
 .TP
-.I /usr/local/etc/dovecot/conf.d/90\-sieve.conf
+.I @pkgsysconfdir@/conf.d/90\-sieve.conf
 Sieve interpreter settings (included from Dovecot\(aqs main configuration file)
 .\"------------------------------------------------------------------------
 @INCLUDE:reporting-bugs@