From zaa@ulstu.ru  Fri May 16 18:16:46 2008
Return-Path: <zaa@ulstu.ru>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 8C2C0106564A
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 16 May 2008 18:16:46 +0000 (UTC)
	(envelope-from zaa@ulstu.ru)
Received: from mx0.ulstu.ru (sirius.ulstu.ru [62.76.34.37])
	by mx1.freebsd.org (Postfix) with ESMTP id B23528FC16
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 16 May 2008 18:16:45 +0000 (UTC)
	(envelope-from zaa@ulstu.ru)
Received: by mx0.ulstu.ru (ulstuMail, from userid 3909)
	id D9EEC5647F; Fri, 16 May 2008 21:51:35 +0400 (MSD)
Message-Id: <20080516175135.D9EEC5647F@mx0.ulstu.ru>
Date: Fri, 16 May 2008 21:51:35 +0400 (MSD)
From: Alexander Zhuravlev <zaa@zaa.pp.ru>
Reply-To: Alexander Zhuravlev <zaa@zaa.pp.ru>
To: FreeBSD-gnats-submit@freebsd.org
Cc: umq@ueo.co.jp
Subject: [PATCH] Fixed mail/dkim-milter build with WITH_POSTFIX_MILTER option being enabled
X-Send-Pr-Version: 3.113
X-GNATS-Notify: umq@ueo.co.jp

>Number:         123738
>Category:       ports
>Synopsis:       [PATCH] Fixed mail/dkim-milter build with WITH_POSTFIX_MILTER option being enabled
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Fri May 16 18:20:02 UTC 2008
>Closed-Date:    Sun May 18 14:32:58 UTC 2008
>Last-Modified:  Sun May 18 14:40:01 UTC 2008
>Originator:     Alexander Zhuravlev
>Release:        FreeBSD 7.0-STABLE amd64
>Organization:
>Environment:
System: FreeBSD sirius.ulstu.ru 7.0-STABLE FreeBSD 7.0-STABLE #1: Sun May 4 16:15:13 MSD 2008 root@sirius.ulstu.ru:/usr/obj/usr/src/sys/SIRIUS-s amd64


	
>Description:
	

I've just tried to build the port with WITH_POSTFIX_MILTER option being enabled and got the error mentioned below:

==========================================================================================
sirius:...mail/dkim-milter> make WITH_POSTFIX_MILTER=yes WITH_VERIFY_DOMAINKEYS=yes install
...
install  -o root -g wheel -m 444 /usr/obj/usr/ports/mail/dkim-milter/work/dkim-milter-2.5.5/libdkim/docs/`/usr/bin/basename /libdkim/rfc2822_mailbox_split.html` /usr/local/share/doc/dkim-milter/libdkim/
cat: pkg-message.postfix: No such file or directory
*** Error code 1

Stop in /usr/ports/mail/dkim-milter.
==========================================================================================


>How-To-Repeat:
	
>Fix:

	I've managed to successfully install the port by applying the following patch.

--- dkim-milter.diff begins here ---
diff -urbN -urbBN dkim-milter.orig/Makefile dkim-milter/Makefile
--- dkim-milter.orig/Makefile	2008-05-15 21:37:08.000000000 +0400
+++ dkim-milter/Makefile	2008-05-16 21:26:17.000000000 +0400
@@ -24,9 +24,14 @@
 USE_RC_SUBR=	milter-dkim.sh
 USE_OPENSSL=	yes
 
+SUB_FILES=	milter-dkim.sh
+SUB_LIST=	RC_SCRIPT=${PREFIX}/etc/rc.d/${USE_RC_SUBR:S/.sh$//}${RC_SUBR_SUFFIX} \
+		DESTDIR=${DESTDIR}
+
 .if defined(WITH_POSTFIX_MILTER) || defined(WITH_POSTFIX) || defined(WITH_POSTFIX_CURRENT)
 WITH_SENDMAIL_BASE=	yes
-PKGMESSAGE=	pkg-message.postfix
+SUB_FILES+=	pkg-message.postfix
+PKGMESSAGE=	${WRKDIR}/pkg-message.postfix
 
 .if defined(SENDMAIL_MILTER_IN_BASE)
 WITH_SENDMAIL_BASE=yes
@@ -39,7 +44,6 @@
 .endif
 .endif
 
-SUB_FILES=	milter-dkim.sh
 WCONF=		${WRKSRC}/devtools/Site
 MAN5=		dkim-filter.conf.5
 MAN8=		dkim-filter.8 dkim-genkey.8 dkim-testkey.8 dkim-testssp.8
@@ -153,8 +157,6 @@
 SITE_SUB+=	-e 's|%%STATIC%%|dnl |g'
 .endif
 
-SUB_LIST=	"RC_SCRIPT=${PREFIX}/etc/rc.d/${USE_RC_SUBR:S/.sh$//}${RC_SUBR_SUFFIX}"
-
 .if defined(WITH_LIBDKIM_SHARED)
 .if ${ARCH} == "amd64"
 BROKEN=		The devtools do not support the feature
diff -urbN -urbBN dkim-milter.orig/files/pkg-message.postfix.in dkim-milter/files/pkg-message.postfix.in
--- dkim-milter.orig/files/pkg-message.postfix.in	1970-01-01 03:00:00.000000000 +0300
+++ dkim-milter/files/pkg-message.postfix.in	2008-05-16 21:27:06.000000000 +0400
@@ -0,0 +1,15 @@
+************************************************************************
+
+In order to run this port, please add the following lines to
+%%PREFIX%%/etc/mail/main.cf:
+
+smtpd_milters = unix:/var/run/milterdkim/filter
+
+And to run the milter from startup, add milterdkim_enable="YES" in
+your %%DESTDIR%%/etc/rc.conf.
+Extra options can be found in startup script.
+
+Note: milter sockets must be accessible from postfix/smtpd;
+  using inet sockets might be preferred.
+
+************************************************************************
diff -urbN -urbBN dkim-milter.orig/pkg-message.postfix dkim-milter/pkg-message.postfix
--- dkim-milter.orig/pkg-message.postfix	2006-10-01 19:06:48.000000000 +0400
+++ dkim-milter/pkg-message.postfix	1970-01-01 03:00:00.000000000 +0300
@@ -1,15 +0,0 @@
-************************************************************************
-
-In order to run this port, please add the following lines to
-${PREFIX}/etc/mail/main.cf:
-
-smtpd_milters = unix:/var/run/milterdkim/filter
-
-And to run the milter from startup, add milterdkim_enable="YES" in
-your /etc/rc.conf.
-Extra options can be found in startup script.
-
-Note: milter sockets must be accessible from postfix/smtpd;
-  using inet sockets might be preferred.
-
-************************************************************************
--- dkim-milter.diff ends here ---


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->feedback 
State-Changed-By: edwin 
State-Changed-When: Fri May 16 18:20:11 UTC 2008 
State-Changed-Why:  
Awaiting maintainers feedback (via the GNATS Auto Assign Tool) 

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

From: Edwin Groothuis <edwin@FreeBSD.org>
To: umq@ueo.co.jp
Cc: bug-followup@FreeBSD.org
Subject: Re: ports/123738: [PATCH] Fixed mail/dkim-milter build with WITH_POSTFIX_MILTER option being enabled
Date: Fri, 16 May 2008 18:20:08 UT

 Maintainer of mail/dkim-milter,
 
 Please note that PR ports/123738 has just been submitted.
 
 If it contains a patch for an upgrade, an enhancement or a bug fix
 you agree on, reply to this email stating that you approve the patch
 and a committer will take care of it.
 
 The full text of the PR can be found at:
     http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/123738
 
 -- 
 Edwin Groothuis via the GNATS Auto Assign Tool
 edwin@FreeBSD.org

From: Hirohisa Yamaguchi <umq@ueo.co.jp>
To: Alexander Zhuravlev <zaa@zaa.pp.ru>, bug-followup@FreeBSD.ORG
Cc:  
Subject: Re: ports/123738: [PATCH] Fixed mail/dkim-milter build with WITH_POSTFIX_MILTER option being enabled
Date: Sat, 17 May 2008 09:51:23 +0900

 Hi,
 
 I could not reproduce the install error here with 7.0-RELEASE-p1.
 pkg-message.postfix's shown correctly.
 
 I don't understand how the patch fixes the problem.
 
 At Fri, 16 May 2008 18:20:08 UT,
 Edwin Groothuis wrote:
 > Please note that PR ports/123738 has just been submitted.
 
 > The full text of the PR can be found at:
 >     http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/123738
 
 -- 
 
 	Hirohisa Yamaguchi
 	  umq@ueo.co.jp

From: Alexander Zhuravlev <zaa@zaa.pp.ru>
To: Hirohisa Yamaguchi <umq@ueo.co.jp>
Cc: bug-followup@FreeBSD.ORG
Subject: Re: ports/123738: [PATCH] Fixed mail/dkim-milter build with WITH_POSTFIX_MILTER option being enabled
Date: Sat, 17 May 2008 05:27:25 +0400

 On Sat, May 17, 2008 at 09:51:23AM +0900, Hirohisa Yamaguchi wrote:
 > Hi,
 > 
 > I could not reproduce the install error here with 7.0-RELEASE-p1.
 > pkg-message.postfix's shown correctly.
 
 Please put the following entry to /etc/make.conf
 
 WRKDIRPREFIX=/usr/obj
 
 then proceed to the /usr/ports/mail/dkim-milter/ and try to install the
 port.
 
 The patch moves pkg-message.postfix to files/pkg-message.postfix.in,
 which is being post-processed (ports system performs replacements of
 %%PREFIX%%, etc in the pkg-message.postfix.in file) and copied to ${WRKDIR}/pkg-message.postfix.
 Then the ports system displays content of the ${WRKDIR}/pkg-message.postfix file.

From: Hirohisa Yamaguchi <umq@ueo.co.jp>
To: zaa@zaa.pp.ru
Cc: bug-followup@FreeBSD.ORG
Subject: Re: ports/123738: [PATCH] Fixed mail/dkim-milter build with WITH_POSTFIX_MILTER option being enabled
Date: Sat, 17 May 2008 11:28:43 +0900

 --Multipart_Sat_May_17_11:28:42_2008-1
 Content-Type: text/plain; charset=US-ASCII
 
 At Sat, 17 May 2008 05:27:25 +0400,
 Alexander Zhuravlev wrote:
 
 > Please put the following entry to /etc/make.conf
 > 
 > WRKDIRPREFIX=/usr/obj
 > 
 > then proceed to the /usr/ports/mail/dkim-milter/ and try to install the
 > port.
 
 Okay, I see the problem.
 Attached patch should work.
 
 I'll consider using SUB_FILES for pkg-message.postfix in the next
 update, since a better instruction for postfix users are discussed in
 upstream.
 So, I keep pkg-message.postfix untouched this time.
 
 
 Regards,
 
 -- 
 
 	Hirohisa Yamaguchi
 	  umq@ueo.co.jp
 
 --Multipart_Sat_May_17_11:28:42_2008-1
 Content-Type: application/octet-stream; type=patch
 Content-Disposition: attachment; filename="dkim-milter.patch"
 Content-Transfer-Encoding: 7bit
 
 Index: Makefile
 ===================================================================
 RCS file: /home/ncvs/ports/mail/dkim-milter/Makefile,v
 retrieving revision 1.48
 diff -u -r1.48 Makefile
 --- Makefile	26 Apr 2008 15:18:44 -0000	1.48
 +++ Makefile	17 May 2008 02:12:10 -0000
 @@ -14,6 +14,7 @@
  
  PORTNAME=	dkim-milter
  PORTVERSION=	2.5.5
 +PORTREVISION=	1
  CATEGORIES=	mail
  MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
  MASTER_SITE_SUBDIR=	${PORTNAME}
 @@ -26,7 +27,7 @@
  
  .if defined(WITH_POSTFIX_MILTER) || defined(WITH_POSTFIX) || defined(WITH_POSTFIX_CURRENT)
  WITH_SENDMAIL_BASE=	yes
 -PKGMESSAGE=	pkg-message.postfix
 +PKGMESSAGE=	${PKGDIR}/pkg-message.postfix
  
  .if defined(SENDMAIL_MILTER_IN_BASE)
  WITH_SENDMAIL_BASE=yes
 
 --Multipart_Sat_May_17_11:28:42_2008-1--
State-Changed-From-To: feedback->closed 
State-Changed-By: miwi 
State-Changed-When: Sun May 18 14:32:56 UTC 2008 
State-Changed-Why:  
Committed. Thanks! 

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

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/123738: commit references a PR
Date: Sun, 18 May 2008 14:32:53 +0000 (UTC)

 miwi        2008-05-18 14:32:48 UTC
 
   FreeBSD ports repository
 
   Modified files:
     mail/dkim-milter     Makefile 
   Log:
   - Fix build with WITH_POSTFIX_MILTER option being enabled
   
   PR:             123738
   Submitted by:   Alexander Zhuravlev <zaa@zaa.pp.ru>
   Approved by:    maintainer
   
   Revision  Changes    Path
   1.49      +2 -1      ports/mail/dkim-milter/Makefile
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
>Unformatted:
