Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 07 Jul 2005 17:15:37 -0400
From:      David Mazieres <dm+bugs+avenger@mailavenger.org>
To:        Pav Lucistnik <pav@FreeBSD.org>
Cc:        freebsd-ports-bugs@FreeBSD.org
Subject:   Re: ports/83077: Update port: mail/avenger to version 0.6.5
Message-ID:  <6cpstus4g6.fsf@vivisex.scs.cs.nyu.edu>
In-Reply-To: <200507072046.j67KkaMf035756@freefall.freebsd.org> (Pav Lucistnik's message of "Thu, 7 Jul 2005 20:46:36 GMT")
References:  <200507072046.j67KkaMf035756@freefall.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
--=-=-=

Pav Lucistnik <pav@FreeBSD.org> writes:

> From: Pav Lucistnik <pav@FreeBSD.org>
> Subject: Re: ports/83077: Update port: mail/avenger to version 0.6.5
>
> Please resubmit the update as an unified diff between old and new port
> directory (diff -ruN old/ new/)

As requested, I'm attaching the patch.

> Also please don't remove hardcoding of UID/GID from pkg-install script.
> It's FreeBSD Ports policy to hardcode UIDs for system users.

I'm slightly confused here.  On the FreeBSD web page, it says:

        http://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/dads-uid-and-gids.html

        If your port requires a certain user to be on the installed
        system, let the pkg-install script call pw to create it
        automatically. Look at net/cvsup-mirror for an example.

        If your port must use the same user/group ID number when it is
        installed as a binary package as when it was compiled, then
        you must choose a free UID from 50 to 999 and register it
        below. Look at japanese/Wnn6 for an example.

This port does not require the same user/group when it is installed as
when it was compiled.  So I looked at net/cvsup-mirror, and it
allocates the uid dynamically.  From this I concluded that I had
messed up in the first port I submitted.

Should I not do what net/cvsup-mirror does?  If so, what UID should I
use.  Last time I used 172, but I now see it has been taken for the
akg user by the AquaGateKeeper port, so I should pick a different
number.  Maybe 175?

Thanks,
David


--=-=-=
Content-Type: text/x-patch
Content-Disposition: inline; filename=patch

diff -ruN old/Makefile new/Makefile
--- old/Makefile	Wed Jul  6 20:07:04 2005
+++ new/Makefile	Wed Jul  6 21:42:24 2005
@@ -6,11 +6,11 @@
 #
 
 PORTNAME=	avenger
-PORTVERSION=	0.6.2
+PORTVERSION=	0.6.5
 CATEGORIES=	mail
 MASTER_SITES=	http://www.mailavenger.org/dist/
 
-MAINTAINER=	ports@FreeBSD.org
+MAINTAINER=	dm+bugs+avenger@mailavenger.org
 COMMENT=	An anti-spam SMTP server
 
 LIB_DEPENDS=	db-4.3:${PORTSDIR}/databases/db43
@@ -23,12 +23,12 @@
 MAN5=		asmtpd.conf.5
 MAN8=		asmtpd.8 avenger.local.8
 
-CONFIGURE_ARGS=	--with-db=${LOCALBASE}
+AVETC=		${PREFIX}/etc
+CONFIGURE_ENV=	WFLAGS='-Wall'
+CONFIGURE_ARGS=	--with-db=${LOCALBASE} --with-etcdir=${AVETC}
 
 post-patch:
-	@${FIND} ${WRKSRC} -type f -exec ${REINPLACE_CMD} -e \
-		's|\(/etc/avenger\)|${PREFIX}\1|g' {} \;
-	@${REINPLACE_CMD} -e 's|-Werror||' ${WRKSRC}/configure
+	rm -f ${WRKSRC}/doc/*.[158]
 
 pre-install:
 	PKG_PREFIX=${PREFIX} ${SH} pkg-install ${PKGNAME} PRE-INSTALL
diff -ruN old/distinfo new/distinfo
--- old/distinfo	Mon May  9 19:19:58 2005
+++ new/distinfo	Wed Jul  6 21:15:44 2005
@@ -1,2 +1,2 @@
-MD5 (avenger-0.6.2.tar.gz) = 40d81f693192d79c1c1a3070f6df54d7
-SIZE (avenger-0.6.2.tar.gz) = 756450
+MD5 (avenger-0.6.5.tar.gz) = cb546fd4872496441c329ff479c488c9
+SIZE (avenger-0.6.5.tar.gz) = 759989
diff -ruN old/files/patch-asmtpd_smtpd.C new/files/patch-asmtpd_smtpd.C
--- old/files/patch-asmtpd_smtpd.C	Fri May 20 02:36:18 2005
+++ new/files/patch-asmtpd_smtpd.C	Wed Dec 31 19:00:00 1969
@@ -1,19 +0,0 @@
---- asmtpd/smtpd.C.orig	Fri May 20 08:10:46 2005
-+++ asmtpd/smtpd.C	Fri May 20 08:11:15 2005
-@@ -88,14 +88,14 @@
-     p++;
- 
-   for (;;) {
--    const char *q = p + min (e - p, 75);
-+    const char *q = p + min ((long) (e - p), (long) 75);
-     if (q != e)
-       while (q > p && !isspace (q[-1]))
- 	q--;
-     while (q > p && isspace (q[-1]))
-       q--;
-     if (q == p) {
--      q = p + min (e - p, 75);
-+      q = p + min ((long) (e - p), (long) 75);
-       while (q < e && !isspace (*q))
- 	q++;
-     }
diff -ruN old/files/patch-libasync_stktrace.c new/files/patch-libasync_stktrace.c
--- old/files/patch-libasync_stktrace.c	Fri May 20 02:36:18 2005
+++ new/files/patch-libasync_stktrace.c	Wed Dec 31 19:00:00 1969
@@ -1,11 +0,0 @@
---- libasync/stktrace.c.orig	Sun Apr 10 03:54:35 2005
-+++ libasync/stktrace.c	Fri May 20 06:52:45 2005
-@@ -144,7 +144,7 @@
- #else /* !gcc 2 || !i386 */
- 
- const char *
--__backtrace (const char *file)
-+__backtrace (const char *file, int lim)
- {
-   return file;
- }
diff -ruN old/pkg-install new/pkg-install
--- old/pkg-install	Mon May  9 19:19:58 2005
+++ new/pkg-install	Wed Jul  6 21:12:11 2005
@@ -6,8 +6,6 @@
 
 USER=avenger
 GROUP=avenger
-UID=172
-GID=172
 AVDIR=/var/spool/avenger
 AVETC=${PKG_PREFIX}/etc/avenger
 
@@ -19,7 +17,7 @@
 
 	if ! ${PW} groupshow $GROUP >/dev/null 2>&1; then
 		echo -n "doesn't exist, adding... "
-		if ${PW} groupadd $GROUP -g ${GID}; then
+		if ${PW} groupadd $GROUP; then
 			echo "success."
 		else
 			echo "FAILED!"
@@ -33,7 +31,7 @@
 
 	if ! ${PW} usershow $USER >/dev/null 2>&1; then
 		echo -n "doesn't exist, adding... "
-		if ${PW} useradd $USER -u ${UID} -c 'Mail Avenger' -d "$AVDIR" -g $GROUP -s /sbin/nologin -h -; then
+		if ${PW} useradd $USER -c 'Mail Avenger' -d "$AVDIR" -g $GROUP -s /sbin/nologin -h -; then
 			echo "success."
 		else
 			echo "FAILED!"

--=-=-=--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6cpstus4g6.fsf>