pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mail/queue-fix Substitute configured qmail users. Bump...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/278f4716b792
branches:  trunk
changeset: 360575:278f4716b792
user:      schmonz <schmonz%pkgsrc.org@localhost>
date:      Tue Apr 04 07:46:14 2017 +0000

description:
Substitute configured qmail users. Bump PKGREVISION.

diffstat:

 mail/queue-fix/Makefile                  |  21 +++++++++++++++++-
 mail/queue-fix/distinfo                  |   3 +-
 mail/queue-fix/patches/patch-queue-fix.c |  35 ++++++++++++++++++++++++++++++++
 3 files changed, 56 insertions(+), 3 deletions(-)

diffs (91 lines):

diff -r 2cf250d260ba -r 278f4716b792 mail/queue-fix/Makefile
--- a/mail/queue-fix/Makefile   Tue Apr 04 07:44:13 2017 +0000
+++ b/mail/queue-fix/Makefile   Tue Apr 04 07:46:14 2017 +0000
@@ -1,7 +1,8 @@
-# $NetBSD: Makefile,v 1.9 2012/10/08 12:19:29 asau Exp $
+# $NetBSD: Makefile,v 1.10 2017/04/04 07:46:14 schmonz Exp $
 #
 
 DISTNAME=              queue-fix-1.4
+PKGREVISION=           1
 CATEGORIES=            mail
 MASTER_SITES=          ${HOMEPAGE}
 
@@ -13,9 +14,25 @@
 
 DJB_RESTRICTED=                NO
 
+SUBST_CLASSES+=                groups
+SUBST_STAGE.groups=    do-configure
+SUBST_FILES.groups=    queue-fix.c
+SUBST_SED.groups=      -e 's,@QMAIL_QMAIL_GROUP@,${QMAIL_QMAIL_GROUP:Q},g'
+
+SUBST_CLASSES+=                users
+SUBST_STAGE.users=     do-configure
+SUBST_FILES.users=     queue-fix.c
+SUBST_SED.users+=      -e 's,@QMAIL_QUEUE_USER@,${QMAIL_QUEUE_USER:Q},g'
+SUBST_SED.users+=      -e 's,@QMAIL_REMOTE_USER@,${QMAIL_REMOTE_USER:Q},g'
+SUBST_SED.users+=      -e 's,@QMAIL_SEND_USER@,${QMAIL_SEND_USER:Q},g'
+
+BUILD_DEFS+=           QMAIL_QUEUE_USER QMAIL_REMOTE_USER QMAIL_SEND_USER
+BUILD_DEFS+=           QMAIL_QMAIL_GROUP
+
+INSTALLATION_DIRS+=    share/doc/queue-fix
+
 do-install:
        ${INSTALL_PROGRAM} ${WRKSRC}/queue-fix ${DESTDIR}${PREFIX}/bin
-       ${INSTALL_DATA_DIR} ${DESTDIR}${PREFIX}/share/doc/queue-fix
        ${INSTALL_DATA} ${WRKSRC}/README ${DESTDIR}${PREFIX}/share/doc/queue-fix
 
 .include "../../mk/djbware.mk"
diff -r 2cf250d260ba -r 278f4716b792 mail/queue-fix/distinfo
--- a/mail/queue-fix/distinfo   Tue Apr 04 07:44:13 2017 +0000
+++ b/mail/queue-fix/distinfo   Tue Apr 04 07:46:14 2017 +0000
@@ -1,6 +1,7 @@
-$NetBSD: distinfo,v 1.4 2015/11/03 23:27:18 agc Exp $
+$NetBSD: distinfo,v 1.5 2017/04/04 07:46:14 schmonz Exp $
 
 SHA1 (queue-fix-1.4.tar.gz) = ce42fcc4daf5076adcf8fea6a9a84f2e1716c67c
 RMD160 (queue-fix-1.4.tar.gz) = 7babeb21844214779dc58b96129ab0ee555393f8
 SHA512 (queue-fix-1.4.tar.gz) = b7e0ac070a409eff156b3803cc1bb78d1c800ae685d107b872bf5b022a8645d1ca55a5c3380f6bc82e99927df8dbf586b74af587e882938b9a7678b506c600e0
 Size (queue-fix-1.4.tar.gz) = 18486 bytes
+SHA1 (patch-queue-fix.c) = 0967151617cf39cc5d88362ae0ed839a947d85f8
diff -r 2cf250d260ba -r 278f4716b792 mail/queue-fix/patches/patch-queue-fix.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/queue-fix/patches/patch-queue-fix.c  Tue Apr 04 07:46:14 2017 +0000
@@ -0,0 +1,35 @@
+$NetBSD: patch-queue-fix.c,v 1.1 2017/04/04 07:46:14 schmonz Exp $
+
+Configure qmail users and groups at build time.
+
+--- queue-fix.c.orig   1999-03-14 19:54:50.000000000 +0000
++++ queue-fix.c
+@@ -729,20 +729,20 @@ struct group * gr;
+       }
+ 
+       /*prepare the uid and gid*/
+-      pw = getpwnam("qmailq");
+-      if(!pw) die_user("qmailq");
++      pw = getpwnam("@QMAIL_QUEUE_USER@");
++      if(!pw) die_user("@QMAIL_QUEUE_USER@");
+       qmailq_uid = pw->pw_uid;
+ 
+-      pw = getpwnam("qmails");
+-      if(!pw) die_user("qmails");
++      pw = getpwnam("@QMAIL_SEND_USER@");
++      if(!pw) die_user("@QMAIL_SEND_USER@");
+       qmails_uid = pw->pw_uid;
+ 
+-      pw = getpwnam("qmailr");
+-      if(!pw) die_user("qmailr");
++      pw = getpwnam("@QMAIL_REMOTE_USER@");
++      if(!pw) die_user("@QMAIL_REMOTE_USER@");
+       qmailr_uid = pw->pw_uid;
+ 
+-      gr = getgrnam("qmail");
+-      if(!gr) die_group("qmail");
++      gr = getgrnam("@QMAIL_QMAIL_GROUP@");
++      if(!gr) die_group("@QMAIL_QMAIL_GROUP@");
+       qmail_gid = gr->gr_gid;
+ 
+       /*check that all the proper directories exist with proper credentials*/



Home | Main Index | Thread Index | Old Index