| @@ -1,86 +1,86 @@ | | | @@ -1,86 +1,86 @@ |
1 | # $NetBSD: Makefile,v 1.28 2011/02/16 19:37:49 shattered Exp $ | | 1 | # $NetBSD: Makefile,v 1.29 2012/01/18 14:35:13 adam Exp $ |
2 | | | 2 | |
3 | DISTNAME= postgrey-1.33 | | 3 | DISTNAME= postgrey-1.33 |
4 | PKGREVISION= 2 | | 4 | PKGREVISION= 3 |
5 | CATEGORIES= mail | | 5 | CATEGORIES= mail |
6 | MASTER_SITES= http://postgrey.schweikert.ch/pub/ | | 6 | MASTER_SITES= http://postgrey.schweikert.ch/pub/ |
7 | | | 7 | |
8 | MAINTAINER= kim@tac.nyc.ny.us | | 8 | MAINTAINER= kim@tac.nyc.ny.us |
9 | HOMEPAGE= http://postgrey.schweikert.ch/ | | 9 | HOMEPAGE= http://postgrey.schweikert.ch/ |
10 | COMMENT= Postfix Greylist Policy Server | | 10 | COMMENT= Postfix Greylist Policy Server |
11 | | | 11 | |
12 | DEPENDS+= p5-BerkeleyDB-[0-9]*:../../databases/p5-BerkeleyDB | | 12 | DEPENDS+= p5-BerkeleyDB-[0-9]*:../../databases/p5-BerkeleyDB |
13 | DEPENDS+= p5-IO-Multiplex-[0-9]*:../../devel/p5-IO-Multiplex | | 13 | DEPENDS+= p5-IO-Multiplex-[0-9]*:../../devel/p5-IO-Multiplex |
14 | DEPENDS+= p5-Net-Server-[0-9]*:../../net/p5-Net-Server | | 14 | DEPENDS+= p5-Net-Server-[0-9]*:../../net/p5-Net-Server |
15 | | | 15 | |
16 | PKG_DESTDIR_SUPPORT= user-destdir | | 16 | PKG_DESTDIR_SUPPORT= user-destdir |
17 | | | 17 | |
18 | BDB_ACCEPTED= db4 db5 | | 18 | BDB_ACCEPTED= db4 db5 |
19 | NO_CONFIGURE= yes | | 19 | NO_CONFIGURE= yes |
20 | USE_TOOLS+= perl:run | | 20 | USE_TOOLS+= perl:run |
21 | | | 21 | |
22 | .include "../../mk/bsd.prefs.mk" | | 22 | .include "../../mk/bsd.prefs.mk" |
23 | | | 23 | |
24 | POSTGREY_USER?= postgrey | | 24 | POSTGREY_USER?= postgrey |
25 | POSTGREY_GROUP?= postgrey | | 25 | POSTGREY_GROUP?= postgrey |
26 | POSTGREY_DBDIR?= ${VARBASE}/db/${PKGBASE} | | 26 | POSTGREY_DBDIR?= ${VARBASE}/db/${PKGBASE} |
27 | | | 27 | |
28 | PKG_SYSCONFSUBDIR?= postfix | | 28 | PKG_SYSCONFSUBDIR?= postfix |
29 | | | 29 | |
30 | DOCDIR= share/doc/${PKGBASE} | | 30 | DOCDIR= share/doc/${PKGBASE} |
31 | EGDIR= share/examples/${PKGBASE} | | 31 | EGDIR= share/examples/${PKGBASE} |
32 | | | 32 | |
33 | RCD_SCRIPTS= postgrey | | 33 | RCD_SCRIPTS= postgrey |
34 | PKG_GROUPS= ${POSTGREY_GROUP} | | 34 | PKG_GROUPS= ${POSTGREY_GROUP} |
35 | PKG_USERS= ${POSTGREY_USER}:${POSTGREY_GROUP} | | 35 | PKG_USERS= ${POSTGREY_USER}:${POSTGREY_GROUP} |
36 | PKG_GROUPS_VARS+= POSTGREY_GROUP | | 36 | PKG_GROUPS_VARS+= POSTGREY_GROUP |
37 | PKG_USERS_VARS+= POSTGREY_USER | | 37 | PKG_USERS_VARS+= POSTGREY_USER |
38 | | | 38 | |
39 | PKG_GECOS.${POSTGREY_USER}= Postgrey Daemon User | | 39 | PKG_GECOS.${POSTGREY_USER}= Postgrey Daemon User |
40 | | | 40 | |
41 | BUILD_DEFS+= POSTGREY_DBDIR VARBASE | | 41 | BUILD_DEFS+= POSTGREY_DBDIR VARBASE |
42 | | | 42 | |
43 | .for i in postgrey_whitelist_clients postgrey_whitelist_recipients | | 43 | .for i in postgrey_whitelist_clients postgrey_whitelist_recipients |
44 | CONF_FILES+= ${PREFIX}/${EGDIR}/${i} \ | | 44 | CONF_FILES+= ${PREFIX}/${EGDIR}/${i} \ |
45 | ${PKG_SYSCONFDIR}/${i} | | 45 | ${PKG_SYSCONFDIR}/${i} |
46 | .endfor | | 46 | .endfor |
47 | | | 47 | |
48 | OWN_DIRS_PERMS+= ${POSTGREY_DBDIR} \ | | 48 | OWN_DIRS_PERMS+= ${POSTGREY_DBDIR} \ |
49 | ${POSTGREY_USER} ${POSTGREY_GROUP} 0775 | | 49 | ${POSTGREY_USER} ${POSTGREY_GROUP} 0775 |
50 | | | 50 | |
51 | FILES_SUBST+= PERL=${PERL5:Q} | | 51 | FILES_SUBST+= PERL=${PERL5:Q} |
52 | | | 52 | |
53 | SUBST_CLASSES+= postgrey | | 53 | SUBST_CLASSES+= postgrey |
54 | SUBST_STAGE.postgrey= pre-build | | 54 | SUBST_STAGE.postgrey= pre-build |
55 | SUBST_FILES.postgrey= postgrey | | 55 | SUBST_FILES.postgrey= postgrey |
56 | # Perl | | 56 | # Perl |
57 | SUBST_SED.postgrey= -e 's,/usr/bin/perl,${PERL5},g' | | 57 | SUBST_SED.postgrey= -e 's,/usr/bin/perl,${PERL5},g' |
58 | # User | | 58 | # User |
59 | SUBST_SED.postgrey+= -e "s,|| 'postgrey',|| '${POSTGREY_USER}',g" | | 59 | SUBST_SED.postgrey+= -e "s,|| 'postgrey',|| '${POSTGREY_USER}',g" |
60 | SUBST_SED.postgrey+= -e "s,default: postgrey,default: ${POSTGREY_USER},g" | | 60 | SUBST_SED.postgrey+= -e "s,default: postgrey,default: ${POSTGREY_USER},g" |
61 | SUBST_SED.postgrey+= -e "s,C<postgrey>,C<${POSTGREY_USER}>,g" | | 61 | SUBST_SED.postgrey+= -e "s,C<postgrey>,C<${POSTGREY_USER}>,g" |
62 | # Group | | 62 | # Group |
63 | SUBST_SED.postgrey+= -e "s,|| 'nogroup',|| '${POSTGREY_GROUP}',g" | | 63 | SUBST_SED.postgrey+= -e "s,|| 'nogroup',|| '${POSTGREY_GROUP}',g" |
64 | SUBST_SED.postgrey+= -e "s,default: nogroup,default: ${POSTGREY_GROUP},g" | | 64 | SUBST_SED.postgrey+= -e "s,default: nogroup,default: ${POSTGREY_GROUP},g" |
65 | # Database | | 65 | # Database |
66 | SUBST_SED.postgrey+= -e 's,/var/spool/postfix/postgrey,${POSTGREY_DBDIR},g' | | 66 | SUBST_SED.postgrey+= -e 's,/var/spool/postfix/postgrey,${POSTGREY_DBDIR},g' |
67 | # Config | | 67 | # Config |
68 | SUBST_SED.postgrey+= -e 's,/etc/postfix,${PKG_SYSCONFDIR},g' | | 68 | SUBST_SED.postgrey+= -e 's,/etc/postfix,${PKG_SYSCONFDIR},g' |
69 | # | | 69 | # |
70 | SUBST_MESSAGE.postgrey= Fixing defaults. | | 70 | SUBST_MESSAGE.postgrey= Fixing defaults. |
71 | | | 71 | |
72 | INSTALLATION_DIRS= sbin ${DOCDIR} ${EGDIR} | | 72 | INSTALLATION_DIRS= sbin ${DOCDIR} ${EGDIR} |
73 | | | 73 | |
74 | do-build: | | 74 | do-build: |
75 | | | 75 | |
76 | do-install: | | 76 | do-install: |
77 | ${INSTALL_SCRIPT} ${WRKSRC}/postgrey ${DESTDIR}${PREFIX}/sbin/postgrey | | 77 | ${INSTALL_SCRIPT} ${WRKSRC}/postgrey ${DESTDIR}${PREFIX}/sbin/postgrey |
78 | .for i in COPYING Changes README | | 78 | .for i in COPYING Changes README |
79 | ${INSTALL_DATA} ${WRKSRC}/${i} ${DESTDIR}${PREFIX}/${DOCDIR}/${i} | | 79 | ${INSTALL_DATA} ${WRKSRC}/${i} ${DESTDIR}${PREFIX}/${DOCDIR}/${i} |
80 | .endfor | | 80 | .endfor |
81 | .for i in postgrey_whitelist_clients postgrey_whitelist_recipients | | 81 | .for i in postgrey_whitelist_clients postgrey_whitelist_recipients |
82 | ${INSTALL_DATA} ${WRKSRC}/${i} ${DESTDIR}${PREFIX}/${EGDIR}/${i} | | 82 | ${INSTALL_DATA} ${WRKSRC}/${i} ${DESTDIR}${PREFIX}/${EGDIR}/${i} |
83 | .endfor | | 83 | .endfor |
84 | | | 84 | |
85 | .include "../../mk/bdb.buildlink3.mk" | | 85 | .include "../../mk/bdb.buildlink3.mk" |
86 | .include "../../mk/bsd.pkg.mk" | | 86 | .include "../../mk/bsd.pkg.mk" |