about summary refs log tree commit diff
path: root/pkgs/servers/mail
diff options
context:
space:
mode:
authorArmijn Hemel <armijn@gpl-violations.org>2006-03-10 23:48:34 +0000
committerArmijn Hemel <armijn@gpl-violations.org>2006-03-10 23:48:34 +0000
commit8befb633d6f853ecd828b25b44671dcb38e4e4a7 (patch)
tree1df5c629a775d3145d57bf9da7cb6b790d3827d1 /pkgs/servers/mail
parent1fdbc347ce6c318f785422810f37226053255475 (diff)
downloadnixlib-8befb633d6f853ecd828b25b44671dcb38e4e4a7.tar
nixlib-8befb633d6f853ecd828b25b44671dcb38e4e4a7.tar.gz
nixlib-8befb633d6f853ecd828b25b44671dcb38e4e4a7.tar.bz2
nixlib-8befb633d6f853ecd828b25b44671dcb38e4e4a7.tar.lz
nixlib-8befb633d6f853ecd828b25b44671dcb38e4e4a7.tar.xz
nixlib-8befb633d6f853ecd828b25b44671dcb38e4e4a7.tar.zst
nixlib-8befb633d6f853ecd828b25b44671dcb38e4e4a7.zip
get postfix to build. Note: install still has to be done, but this will
probably be a bit tricky, due to sendmail "compatibility" (postfix makes
a symlink to "sendmail", so programs will keep on working).

svn path=/nixpkgs/trunk/; revision=5030
Diffstat (limited to 'pkgs/servers/mail')
-rw-r--r--pkgs/servers/mail/postfix/default.nix13
-rw-r--r--pkgs/servers/mail/postfix/postfix-2.2.9-db.patch40
-rw-r--r--pkgs/servers/mail/postfix/postfix-2.2.9-lib.patch12
3 files changed, 65 insertions, 0 deletions
diff --git a/pkgs/servers/mail/postfix/default.nix b/pkgs/servers/mail/postfix/default.nix
new file mode 100644
index 000000000000..7e903dac872e
--- /dev/null
+++ b/pkgs/servers/mail/postfix/default.nix
@@ -0,0 +1,13 @@
+{stdenv, fetchurl, db4, glibc}:
+
+stdenv.mkDerivation {
+  name = "postfix-2.2.9";
+  src = fetchurl {
+    url = ftp://ftp.cs.uu.nl/mirror/postfix/postfix-release/official/postfix-2.2.9.tar.gz;
+    md5 = "be78631bd9b6bf7735e43abfa54d69f6";
+  };
+
+  buildinputs = [db4];
+  patches = [./postfix-2.2.9-db.patch ./postfix-2.2.9-lib.patch];
+  inherit glibc;
+}
diff --git a/pkgs/servers/mail/postfix/postfix-2.2.9-db.patch b/pkgs/servers/mail/postfix/postfix-2.2.9-db.patch
new file mode 100644
index 000000000000..65f55ffd8f05
--- /dev/null
+++ b/pkgs/servers/mail/postfix/postfix-2.2.9-db.patch
@@ -0,0 +1,40 @@
+diff -ruN postfix-2.2.9/makedefs postfix-2.2.9.new/makedefs
+--- postfix-2.2.9/makedefs	2006-01-03 21:50:25.000000000 +0000
++++ postfix-2.2.9.new/makedefs	2006-03-11 00:38:30.000000000 +0000
+@@ -219,21 +219,21 @@
+ 		;;
+     Linux.2*)	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
++		#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
diff --git a/pkgs/servers/mail/postfix/postfix-2.2.9-lib.patch b/pkgs/servers/mail/postfix/postfix-2.2.9-lib.patch
new file mode 100644
index 000000000000..03dcaa87f238
--- /dev/null
+++ b/pkgs/servers/mail/postfix/postfix-2.2.9-lib.patch
@@ -0,0 +1,12 @@
+diff -ruN postfix-2.2.9/makedefs postfix-2.2.9.new/makedefs
+--- postfix-2.2.9/makedefs	2006-01-03 21:50:25.000000000 +0000
++++ postfix-2.2.9.new/makedefs	2006-03-11 01:40:30.000000000 +0000
+@@ -247,7 +247,7 @@
+ 		SYSLIBS="-ldb"
+ 		for name in nsl resolv $GDBM_LIBS
+ 		do
+-		    for lib in /usr/lib64 /lib64 /usr/lib /lib
++		    for lib in $glibc/usr/lib64 $glibc/lib64 $glibc/usr/lib $glibc/lib
+ 		    do
+ 			test -e $lib/lib$name.a -o -e $lib/lib$name.so && {
+ 			    SYSLIBS="$SYSLIBS -l$name"