From sunpoet@IRIS.sunpoet.net  Sat Mar 27 05:01:14 2004
Return-Path: <sunpoet@IRIS.sunpoet.net>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id B494016A4CE
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 27 Mar 2004 05:01:14 -0800 (PST)
Received: from IRIS.sunpoet.net (sunpoet.net [203.204.205.212])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 2E26443D31
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 27 Mar 2004 05:01:14 -0800 (PST)
	(envelope-from sunpoet@IRIS.sunpoet.net)
Received: by IRIS.sunpoet.net (Postfix, from userid 1000)
	id F25821707F; Sat, 27 Mar 2004 21:00:33 +0800 (CST)
Message-Id: <20040327130033.F25821707F@IRIS.sunpoet.net>
Date: Sat, 27 Mar 2004 21:00:33 +0800 (CST)
From: Sunpoet Po-Chuan Hsieh <sunpoet@sunpoet.net>
Reply-To: Sunpoet Po-Chuan Hsieh <sunpoet@sunpoet.net>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: [mail/postfix] Enable users to build Postfix with Berkeley DB 4.2
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         64801
>Category:       ports
>Synopsis:       [mail/postfix] Enable users to build Postfix with Berkeley DB 4.2
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sat Mar 27 05:10:20 PST 2004
>Closed-Date:    Mon Mar 29 08:14:12 PST 2004
>Last-Modified:  Mon Mar 29 08:14:12 PST 2004
>Originator:     Sunpoet Po-Chuan Hsieh
>Release:        FreeBSD 5.2-CURRENT i386
>Organization:
SUNPOET.net
>Environment:
System: FreeBSD IRIS.sunpoet.net 5.2-CURRENT FreeBSD 5.2-CURRENT #0: Tue Mar 23 18:25:35 CST 2004 sunpoet@IRIS.sunpoet.net:/usr/src/sys/i386/compile/sunpoet i386

	
>Description:
This PR enables users to build postfix with Berkeley 4.2. Original configure script includes only Berkeley DB 3, 4.0 and 4.1.

	
>How-To-Repeat:
% cd /usr/ports/mail/postfix
% make

	
>Fix:
% cd /usr/ports/mail/postfix; diff scripts/configure.postfix.orig scripts/configure.postfix
--- scripts/configure.postfix.orig	Thu Mar 11 16:23:06 2004
+++ scripts/configure.postfix	Sat Mar 27 20:05:26 2004
@@ -29,6 +29,7 @@
 DB3		"Berkeley DB3 (required if SASL also built with DB3)" "$status_DB3" \
 DB40		"Berkeley DB4.0 (required if SASL also built with DB4.0)" "$status_DB40" \
 DB41		"Berkeley DB4.1 (required if SASL also built with DB4.1)" "$status_DB41" \
+DB42		"Berkeley DB4.2 (required if SASL also built with DB4.2)" "$status_DB42" \
 MySQL		"MySQL map lookups (choose version with WITH_MYSQL_VER)" "$status_MySQL" \
 PgSQL		"PostgreSQL v7.4 map lookups" "$status_PgSQL" \
 PgSQL73		"PostgreSQL v7.3 map lookups" "$status_PgSQL73" \
@@ -114,8 +115,8 @@
 			SUB_TLS=""
 			;;
 		DB3)
-			if [ X$DB40_SELECTED != "X" -o X$DB41_SELECTED != "X" ]; then
-				/usr/bin/dialog --msgbox "Select exactly one of the DB3, DB40 and DB41 options." 5 60 > /dev/stderr
+			if [ "X$BDB_SELECTED" != "X" ]; then
+				/usr/bin/dialog --msgbox "Select exactly one of the DB3, DB40, DB41 and DB42 options." 5 60 > /dev/stderr
 				rm -f ${WRKDIRPREFIX}${CURDIR}/Makefile.inc
 				exit 1
 			fi
@@ -123,11 +124,11 @@
 			echo "POSTFIX_CCARGS+=	-I\${LOCALBASE}/include/db3"
 			echo "POSTFIX_AUXLIBS+=	-L\${LOCALBASE}/lib -ldb3"
 			echo "DB_SUFFIX=	+db3"
-			DB3_SELECTED="YES"
+			BDB_SELECTED="3"
 			;;
 		DB40)
-			if [ X$DB3_SELECTED != "X" -o X$DB41_SELECTED != "X" ]; then
-				/usr/bin/dialog --msgbox "Select exactly one of the DB3, DB40 and DB41 options." 5 60 > /dev/stderr
+			if [ "X$BDB_SELECTED" != "X" ]; then
+				/usr/bin/dialog --msgbox "Select exactly one of the DB3, DB40, DB41 and DB42 options." 5 60 > /dev/stderr
 				rm -f ${WRKDIRPREFIX}${CURDIR}/Makefile.inc
 				exit 1
 			fi
@@ -135,11 +136,11 @@
 			echo "POSTFIX_CCARGS+=	-I\${LOCALBASE}/include/db4"
 			echo "POSTFIX_AUXLIBS+=	-L\${LOCALBASE}/lib -ldb4"
 			echo "DB_SUFFIX=	+db40"
-			DB40_SELECTED="YES"
+			BDB_SELECTED="40"
 			;;
 		DB41)
-			if [ X$DB3_SELECTED != "X" -o X$DB40_SELECTED != "X" ]; then
-				/usr/bin/dialog --msgbox "Select exactly one of the DB3, DB40 and DB41 options." 5 60 > /dev/stderr
+			if [ "X$BDB_SELECTED" != "X" ]; then
+				/usr/bin/dialog --msgbox "Select exactly one of the DB3, DB40, DB41 and DB42 options." 5 60 > /dev/stderr
 				rm -f ${WRKDIRPREFIX}${CURDIR}/Makefile.inc
 				exit 1
 			fi
@@ -147,7 +148,19 @@
 			echo "POSTFIX_CCARGS+=	-I\${LOCALBASE}/include/db41"
 			echo "POSTFIX_AUXLIBS+=	-L\${LOCALBASE}/lib -ldb41"
 			echo "DB_SUFFIX=	+db41"
-			DB41_SELECTED="YES"
+			BDB_SELECTED="41"
+			;;
+		DB42)
+			if [ "X$BDB_SELECTED" != "X" ]; then
+				/usr/bin/dialog --msgbox "Select exactly one of the DB3, DB40, DB41 and DB42 options." 5 60 > /dev/stderr
+				rm -f ${WRKDIRPREFIX}${CURDIR}/Makefile.inc
+				exit 1
+			fi
+			echo "LIB_DEPENDS+=	db-4.2.2:\${PORTSDIR}/databases/db42"
+			echo "POSTFIX_CCARGS+=	-I\${LOCALBASE}/include/db42"
+			echo "POSTFIX_AUXLIBS+=	-L\${LOCALBASE}/lib/db42/ -ldb"
+			echo "DB_SUFFIX=	+db42"
+			BDB_SELECTED="42"
 			;;
 		MySQL)
 			echo "USE_MYSQL=YES"
	


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->feedback 
State-Changed-By: pav 
State-Changed-When: Sat Mar 27 06:23:16 PST 2004 
State-Changed-Why:  
Asked maintainer for approval. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=64801 

From: Pav Lucistnik <pav@FreeBSD.org>
To: freebsd-gnats-submit@FreeBSD.org, sunpoet@sunpoet.net,
	vivek@khera.org
Cc:  
Subject: Re: ports/64801: [mail/postfix] Enable users to build Postfix with
	Berkeley DB 4.2
Date: Sat, 27 Mar 2004 15:23:13 +0100

 Dear maintainer of FreeBSD port mail/postfix, please take a look at
 
 http://www.freebsd.org/cgi/query-pr.cgi?q=64801
 
 Do you approve this change?
 
 -- 
 Pav Lucistnik <pav@oook.cz>
               <pav@FreeBSD.org>
 
  I went grocery shopping, made a pot of chilli, played ey,
 then ate some chilli

From: Vivek Khera <vivek@khera.org>
To: sunpoet@sunpoet.net, freebsd-gnats-submit@FreeBSD.org
Cc:  
Subject: Re: ports/64801: [mail/postfix] Enable users to build Postfix with Berkeley DB 4.2
Date: Mon, 29 Mar 2004 10:27:32 -0500

 Looks ok to me.  Please go ahead and commit it.  Thanks.
 
State-Changed-From-To: feedback->closed 
State-Changed-By: pav 
State-Changed-When: Mon Mar 29 08:13:57 PST 2004 
State-Changed-Why:  
Committed, thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=64801 
>Unformatted:
