Lines 6-20
Link Here
|
6 |
# |
6 |
# |
7 |
|
7 |
|
8 |
PORTNAME= dcc-dccd |
8 |
PORTNAME= dcc-dccd |
9 |
PORTVERSION= 1.3.50 |
9 |
PORTVERSION= 1.3.86 |
10 |
PORTREVISION= 1 |
10 |
PORTREVISION= 0 |
11 |
CATEGORIES= mail |
11 |
CATEGORIES= mail |
12 |
MASTER_SITES= http://www.rhyolite.com/anti-spam/dcc/source/ \ |
12 |
MASTER_SITES= http://www.dcc-servers.net/dcc/source/old/ \ |
13 |
http://www.wa.apana.org.au/~dean/sources/ |
13 |
http://www.rhyolite.com/anti-spam/dcc/source/old/ \ |
|
|
14 |
ftp://ftp.dcc-servers.net/src/dcc/old/ \ |
15 |
ftp://ftp.rhyolite.com/src/dcc/old/ |
16 |
DISTNAME= dcc-1.3.86 |
14 |
EXTRACT_SUFX= .tar.Z |
17 |
EXTRACT_SUFX= .tar.Z |
15 |
|
18 |
|
16 |
MAINTAINER= dean@odyssey.apana.org.au |
19 |
MAINTAINER= dean@odyssey.apana.org.au |
17 |
COMMENT= Distributed Checksum Clearinghouse procmail, sendmail support |
20 |
COMMENT= Distributed Checksum Clearinghouse bulk email detector |
18 |
|
21 |
|
19 |
HAS_CONFIGURE= yes |
22 |
HAS_CONFIGURE= yes |
20 |
MANCOMPRESSED= yes |
23 |
MANCOMPRESSED= yes |
Lines 24-68
Link Here
|
24 |
PKGINSTALL= ${WRKDIR}/pkg-install |
27 |
PKGINSTALL= ${WRKDIR}/pkg-install |
25 |
PKGDEINSTALL= ${WRKDIR}/pkg-deinstall |
28 |
PKGDEINSTALL= ${WRKDIR}/pkg-deinstall |
26 |
|
29 |
|
27 |
USE_RC_SUBR= dcc-start.sh |
30 |
USE_RC_SUBR= |
28 |
|
31 |
|
29 |
# |
32 |
# |
30 |
# User for dcc files and SUID binaries |
33 |
# ALT_HOME - DCC keeps its config files in its home direcotry but writes |
|
|
34 |
# status and database files there as well. This latter point |
35 |
# means that the FreeBSD default home directory for DCC, |
36 |
# /usr/local/dcc, cannot be mounted read-only. |
37 |
# |
38 |
# DCC's default home dir is /var/dcc breaks FreeBSD hierarchy |
39 |
# conventions, but allows for a read-only /usr. |
40 |
# |
41 |
# Setting ALT_HOME on will set DCC's home to /var/dcc, but |
42 |
# keep its binaries in /usr/local/dcc/libexec. Since this |
43 |
# also means DCC's config files will be in /var/dcc, for |
44 |
# convenience a soft link from /usr/local/etc/dcc to /var/dcc |
45 |
# may be created. |
46 |
# |
47 |
# Note also that dccifd's default socket location is DCC's |
48 |
# home, so if /var/dcc is used for the home, then programs |
49 |
# like SpamAssassin may need to be explicitly told where |
50 |
# to find dccifd's socket. |
51 |
# |
52 |
OPTIONS= DCCIFD "DCC interface daemon (for SpamAssassin etc)" on \ |
53 |
DCCM "DCC milter (for Sendmail only)" off \ |
54 |
DCCD "DCC server" off \ |
55 |
DCCGREY "DCC greylisting server" off \ |
56 |
IPV6 "IPv6 support" on \ |
57 |
ALT_HOME "DCC home in /var/dcc" off \ |
58 |
PORTS_SENDMAIL "Use base Sendmail if off, ports if on" off |
59 |
|
60 |
|
61 |
|
62 |
## User for DCC files and SUID binaries |
31 |
# |
63 |
# |
32 |
DCCUSER?= dcc |
64 |
DCCUSER?= dcc |
33 |
DCCUID?= 112 |
65 |
DCCUID?= 112 |
34 |
DCCGROUP?= dcc |
66 |
DCCGROUP?= dcc |
35 |
DCCGID?= 112 |
67 |
DCCGID?= 112 |
36 |
|
68 |
|
37 |
# |
|
|
38 |
# Use configure script to set locations of all files. Use of |
39 |
# sed scripting breaks things. |
40 |
# |
41 |
|
69 |
|
42 |
CONFIGURE_ARGS= --homedir=${PREFIX}/dcc --bindir=${PREFIX}/bin --mandir=${MANPREFIX}/man --with-rundir=/var/run/dcc |
70 |
## Use the configure script to explicitly set the locations of all files, |
|
|
71 |
## in case the standard locations have been locally overridden |
72 |
# |
73 |
CONFIGURE_ARGS= --with-uid=${DCCUSER} --bindir=${PREFIX}/bin --mandir=${MANPREFIX}/man --with-configsuffix=.sample |
43 |
|
74 |
|
44 |
.include <bsd.port.pre.mk> |
75 |
.include <bsd.port.pre.mk> |
45 |
|
76 |
|
46 |
.if !defined(WITH_SENDMAIL_BASE) && !defined(WITH_SENDMAIL_PORT) && !exists(${LOCALBASE}/lib/libmilter.a) |
77 |
SUB_FILES= pkg-message |
47 |
WITH_SENDMAIL_BASE=yes |
78 |
SUB_LIST+= WRKSRC=${WRKSRC} |
48 |
.endif |
|
|
49 |
|
79 |
|
50 |
.if defined(WITH_SENDMAIL_BASE) |
80 |
## /var/dcc home support |
51 |
.if exists(/usr/lib/libmilter.a) |
81 |
# |
52 |
MILTERBASE= /usr |
82 |
.if defined(WITH_ALT_HOME) |
53 |
WITH_SENDMAIL= yes |
83 |
CONFIGURE_ARGS+= --homedir=/var/dcc --libexecdir=${PREFIX}/dcc/libexec --with-cgibin=${PREFIX}/dcc/cgi-bin |
|
|
84 |
SUB_LIST+= DCCHOME=/var/dcc |
85 |
PLIST_SUB+= WITH_ALT_HOME="" |
54 |
.else |
86 |
.else |
55 |
.if !defined(WITHOUT_SENDMAIL) |
87 |
CONFIGURE_ARGS+= --homedir=${PREFIX}/dcc |
56 |
IGNORE= base system sendmail not found or too old, rebuild with WITH_SENDMAIL_PORT=yes or WITHOUT_SENDMAIL=yes |
88 |
SUB_LIST+= DCCHOME=${PREFIX}/dcc |
|
|
89 |
PLIST_SUB+= WITH_ALT_HOME="@comment " |
57 |
.endif |
90 |
.endif |
|
|
91 |
|
92 |
## dccm milter support |
93 |
# |
94 |
.if defined(WITH_DCCM) |
95 |
|
96 |
.if !exists(/usr/lib/libmilter.a) && !exists(${LOCALBASE}/lib/libmilter.a) |
97 |
IGNORE= Neither base system nor Ports version of Sendmail installed, cannot build milter |
98 |
.endif |
99 |
.if defined(WITHOUT_PORTS_SENDMAIL) && !exists(/usr/lib/libmilter.a) |
100 |
IGNORE= Base system Sendmail not found or too old, rebuild with WITH_PORTS_SENDMAIL=yes or WITHOUT_DCCM=yes |
58 |
.endif |
101 |
.endif |
|
|
102 |
.if defined(WITH_PORTS_SENDMAIL) && !exists(${LOCALBASE}/lib/libmilter.a) |
103 |
IGNORE= Ports Sendmail not found, rebuild with WITHOUT_PORTS_SENDMAIL=yes or WITHOUT_DCCM=yes |
104 |
.endif |
105 |
|
106 |
.if defined(WITHOUT_PORTS_SENDMAIL) |
107 |
MILTERBASE= /usr |
59 |
.else |
108 |
.else |
60 |
BUILD_DEPENDS+= ${LOCALBASE}/lib/libmilter.a:${PORTSDIR}/mail/sendmail |
109 |
BUILD_DEPENDS+= ${LOCALBASE}/lib/libmilter.a:${PORTSDIR}/mail/sendmail |
61 |
MILTERBASE?= ${LOCALBASE} |
110 |
MILTERBASE?= ${LOCALBASE} |
62 |
WITH_SENDMAIL= yes |
|
|
63 |
.endif |
111 |
.endif |
64 |
|
112 |
|
65 |
.if !defined(WITHOUT_SENDMAIL) && defined(WITH_SENDMAIL) |
|
|
66 |
MILTERINC= ${MILTERBASE}/include |
113 |
MILTERINC= ${MILTERBASE}/include |
67 |
MILTERLIB= ${MILTERBASE}/lib |
114 |
MILTERLIB= ${MILTERBASE}/lib |
68 |
|
115 |
|
Lines 71-105
Link Here
|
71 |
|
118 |
|
72 |
CONFIGURE_ENV+= CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}" |
119 |
CONFIGURE_ENV+= CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}" |
73 |
CONFIGURE_ARGS+= --with-sendmail=${MILTERBASE} |
120 |
CONFIGURE_ARGS+= --with-sendmail=${MILTERBASE} |
74 |
PLIST_SUB+= WITH_SENDMAIL="" |
121 |
|
|
|
122 |
PLIST_SUB+= WITH_DCCM="" |
123 |
|
124 |
USE_RC_SUBR+= dccm.sh |
125 |
|
75 |
.else |
126 |
.else |
76 |
CONFIGURE_ARGS+= --disable-dccm |
127 |
CONFIGURE_ARGS+= --disable-dccm |
77 |
PLIST_SUB+= WITH_SENDMAIL="@comment " |
128 |
PLIST_SUB+= WITH_DCCM="@comment " |
78 |
.endif |
129 |
.endif |
79 |
|
130 |
|
|
|
131 |
## dccifd client interface daemon support |
132 |
# |
80 |
.if defined(WITHOUT_DCCIFD) |
133 |
.if defined(WITHOUT_DCCIFD) |
81 |
CONFIGURE_ARGS+= --disable-dccifd |
134 |
CONFIGURE_ARGS+= --disable-dccifd |
82 |
PLIST_SUB+= WITH_DCCIFD="@comment " |
135 |
PLIST_SUB+= WITH_DCCIFD="@comment " |
83 |
.else |
136 |
.else |
84 |
PLIST_SUB+= WITH_DCCIFD="" |
137 |
PLIST_SUB+= WITH_DCCIFD="" |
|
|
138 |
USE_RC_SUBR+= dccifd.sh |
85 |
.endif |
139 |
.endif |
86 |
|
140 |
|
87 |
CONFIGURE_ARGS+= --with-uid=${DCCUSER} |
141 |
## dccd server support |
|
|
142 |
# |
143 |
.if defined(WITHOUT_DCCD) && defined(WITHOUT_DCCGREY) |
144 |
CONFIGURE_ARGS+= --disable-server |
145 |
PLIST_SUB+= WITH_DCCD="@comment " |
146 |
.else |
147 |
PLIST_SUB+= WITH_DCCD="" |
148 |
.endif |
149 |
|
150 |
## IPV6 support |
151 |
# |
152 |
.if defined(WITHOUT_IPV6) |
153 |
CONFIGURE_ARGS+= --disable-IPv6 |
154 |
.endif |
88 |
|
155 |
|
|
|
156 |
|
157 |
## Packing list and rcNG script fixups |
158 |
# |
159 |
.if defined(WITHOUT_DCCIFD) && defined(WITHOUT_DCCM) |
160 |
PLIST_SUB+= WITH_IFD_MILT="@comment " |
161 |
.else |
162 |
PLIST_SUB+= WITH_IFD_MILT="" |
163 |
.endif |
164 |
|
165 |
.if defined(WITH_DCCD) |
166 |
USE_RC_SUBR+= dccd.sh |
167 |
.endif |
168 |
|
169 |
.if defined(WITH_DCCGREY) |
170 |
USE_RC_SUBR+= dccgrey.sh |
171 |
PLIST_SUB+= WITH_DCCGREY="" |
172 |
.else |
173 |
PLIST_SUB+= WITH_DCCGREY="@comment " |
174 |
.endif |
175 |
|
176 |
## Substitutions in pkg-install and pkg-deinstall |
177 |
# |
89 |
SED_SCRIPT= -e 's|%%PREFIX%%|${PREFIX}|g' \ |
178 |
SED_SCRIPT= -e 's|%%PREFIX%%|${PREFIX}|g' \ |
90 |
-e 's|%%DCCUSER%%|${DCCUSER}|g' -e 's|%%DCCUID%%|${DCCUID}|g' \ |
179 |
-e 's|%%DCCUSER%%|${DCCUSER}|g' -e 's|%%DCCUID%%|${DCCUID}|g' \ |
91 |
-e 's|%%DCCGROUP%%|${DCCGROUP}|g' -e 's|%%DCCGID%%|${DCCGID}|g' |
180 |
-e 's|%%DCCGROUP%%|${DCCGROUP}|g' -e 's|%%DCCGID%%|${DCCGID}|g' \ |
|
|
181 |
-e 's|%%DCCHOME%%|${DCCHOME}|g' |
182 |
|
92 |
|
183 |
|
93 |
pre-everything:: |
184 |
pre-everything:: |
94 |
@${ECHO_MSG} ' ' |
185 |
@${ECHO_MSG} ' ' |
95 |
@${ECHO_MSG} 'You can choose the sendmail to be used by specifying:' |
186 |
@${ECHO_MSG} 'A description of ALT_HOME may be found in the port's Makefile.' |
96 |
@${ECHO_MSG} ' ' |
187 |
@${ECHO_MSG} ' ' |
97 |
@${ECHO_MSG} 'WITH_SENDMAIL_BASE=yes' |
|
|
98 |
@${ECHO_MSG} 'or' |
99 |
@${ECHO_MSG} 'WITH_SENDMAIL_PORT=yes' |
100 |
@${ECHO_MSG} 'or' |
101 |
@${ECHO_MSG} 'WITHOUT_SENDMAIL=yes' |
102 |
@${ECHO_MSG} '' |
103 |
|
188 |
|
104 |
post-build: |
189 |
post-build: |
105 |
@${SED} ${SED_SCRIPT} ${PKGDIR}/pkg-install >${PKGINSTALL} |
190 |
@${SED} ${SED_SCRIPT} ${PKGDIR}/pkg-install >${PKGINSTALL} |
Lines 109-112
Link Here
|
109 |
@${SETENV} PKG_PREFIX=${PREFIX} \ |
194 |
@${SETENV} PKG_PREFIX=${PREFIX} \ |
110 |
${SH} ${PKGINSTALL} ${PREFIX} PRE-INSTALL |
195 |
${SH} ${PKGINSTALL} ${PREFIX} PRE-INSTALL |
111 |
|
196 |
|
|
|
197 |
|
198 |
post-install: |
199 |
|
200 |
## Make certain DCC's config files are owned by DCC's user |
201 |
# |
202 |
.if defined(WITH_ALT_HOME) |
203 |
@${CHOWN} ${DCCUSER} /var/dcc/* |
204 |
.else |
205 |
@${CHOWN} ${DCCUSER} ${PREFIX}/dcc/* |
206 |
.endif |
207 |
|
208 |
## Print DCC installation notes and RESTRICTIONS file info |
209 |
# |
210 |
@${CAT} ${PKGMESSAGE} |
211 |
|
212 |
|
112 |
.include <bsd.port.post.mk> |
213 |
.include <bsd.port.post.mk> |