diff -ruN rpmbuild-orig/SOURCES/postfix-2.6.6-makedefs-3.x-kernel.patch rpmbuild/SOURCES/postfix-2.6.6-makedefs-3.x-kernel.patch
--- rpmbuild-orig/SOURCES/postfix-2.6.6-makedefs-3.x-kernel.patch	1970-01-01 01:00:00.000000000 +0100
+++ rpmbuild/SOURCES/postfix-2.6.6-makedefs-3.x-kernel.patch	2014-08-24 13:47:29.000000000 +0200
@@ -0,0 +1,72 @@
+diff -ru postfix-2.6.6-orig/makedefs postfix-2.6.6/makedefs
+--- postfix-2.6.6-orig/makedefs	2009-10-19 02:30:12.000000000 +0200
++++ postfix-2.6.6/makedefs	2014-08-24 13:24:10.333393886 +0200
+@@ -325,6 +325,68 @@
+ 			   rm -f makedefs.test makedefs.test.[co];;
+ 		esac
+ 		;;
++    Linux.3*)	SYSTYPE=LINUX2
++		# Postfix no longer needs DB 1.85 compatibility
++		if [ -f /usr/include/db.h ]
++		then
++		    : we are all set
++		elif [ -f /usr/include/db/db.h ]
++		then
++		    CCARGS="$CCARGS -I/usr/include/db"
++		else
++		    # No, we're not going to try db1 db2 db3 etc.
++		    # On a properly installed system, Postfix builds
++		    # by including <db.h> and by linking with -ldb
++		    echo "No <db.h> include file found." 1>&2
++		    echo "Install the appropriate db*-devel package first." 1>&2
++		    echo "See the RELEASE_NOTES file for more information." 1>&2
++		    exit 1
++		fi
++		# GDBM locks the DBM .pag file after open. This breaks postmap.
++		# if [ -f /usr/include/gdbm-ndbm.h ]
++		# then
++		#     CCARGS="$CCARGS -DHAS_DBM -DPATH_NDBM_H='<gdbm-ndbm.h>'"
++		#     GDBM_LIBS=gdbm
++		# elif [ -f /usr/include/gdbm/ndbm.h ]
++		# then
++		#     CCARGS="$CCARGS -DHAS_DBM -DPATH_NDBM_H='<gdbm/ndbm.h>'"
++		#     GDBM_LIBS=gdbm
++		# fi
++		SYSLIBS="-ldb"
++		for name in nsl resolv $GDBM_LIBS
++		do
++		    for lib in /usr/lib64 /lib64 /usr/lib /lib
++		    do
++			test -e $lib/lib$name.a -o -e $lib/lib$name.so && {
++			    SYSLIBS="$SYSLIBS -l$name"
++			    break
++			}
++		    done
++		done
++		trap 'rm -f makedefs.test makedefs.test.[co]' 1 2 3 15
++		cat >makedefs.test.c <<'EOF'
++#include <sys/types.h>
++#include <sys/epoll.h>
++#include <errno.h>
++#include <stdio.h>
++#include <stdlib.h>
++
++int     main(int argc, char **argv)
++{
++    int     epoll_handle;
++
++    if ((epoll_handle = epoll_create(1)) < 0) {
++	perror("epoll_create");
++	exit(1);
++    }
++    exit(0);
++}
++EOF
++			   ${CC-gcc} -o makedefs.test makedefs.test.c || exit 1
++			   ./makedefs.test 2>/dev/null ||
++				CCARGS="$CCARGS -DNO_EPOLL"
++			   rm -f makedefs.test makedefs.test.[co]
++		;;
+      GNU.0*|GNU/kFreeBSD.[567]*)
+      		SYSTYPE=GNU0
+ 		# Postfix no longer needs DB 1.85 compatibility
diff -ruN rpmbuild-orig/SPECS/postfix.spec rpmbuild/SPECS/postfix.spec
--- rpmbuild-orig/SPECS/postfix.spec	2014-02-13 17:24:57.000000000 +0100
+++ rpmbuild/SPECS/postfix.spec	2014-08-24 13:30:53.000000000 +0200
@@ -35,7 +35,7 @@
 Name: postfix
 Summary: Postfix Mail Transport Agent
 Version: 2.6.6
-Release: 6%{?dist}
+Release: 6%{?dist}.0
 Epoch: 2
 Group: System Environment/Daemons
 URL: http://www.postfix.org
@@ -76,6 +76,7 @@
 Patch9: pflogsumm-1.1.1-datecalc.patch
 Patch10: postfix-2.6.6-CVE-2011-0411.patch
 Patch11: postfix-2.6.6-CVE-2011-1720.patch
+Patch10000: postfix-2.6.6-makedefs-3.x-kernel.patch
 
 # Optional patches - set the appropriate environment variables to include
 #                    them when building the package/spec file
@@ -171,6 +172,8 @@
 		touch -r ${f}{,_} && mv -f ${f}{_,}
 done
 
+%patch10000 -p1
+
 %build
 CCARGS=-fPIC
 AUXLIBS=
