Lines 13-19
Link Here
|
13 |
COMMENT= Berkeley POP 3 server (now maintained by Qualcomm) |
13 |
COMMENT= Berkeley POP 3 server (now maintained by Qualcomm) |
14 |
USE_AUTOTOOLS= autoconf |
14 |
USE_AUTOTOOLS= autoconf |
15 |
USE_OPENSSL= yes |
|
|
16 |
CONFIGURE_ENV= LIBS="-lcrypt -lmd -lutil -L${LOCALBASE}/lib" \ |
15 |
CONFIGURE_ENV= LIBS="-lcrypt -lmd -lutil -L${LOCALBASE}/lib" \ |
17 |
OS_DEFS="-DSETPROCTITLE ${OS_DEFS}" |
16 |
OS_DEFS="-DSETPROCTITLE ${OS_DEFS}" |
18 |
CONFIGURE_ARGS= --enable-nonauth-file=${POPUSERS_FILE} \ |
17 |
CONFIGURE_ARGS= --enable-nonauth-file=${POPUSERS_FILE} \ |
Lines 21-28
Link Here
|
21 |
--enable-keep-temp-drop |
20 |
--enable-keep-temp-drop |
22 |
PLIST_SUB= EPOPPASSD=${EPOPPASSD} \ |
21 |
PLIST_SUB= EPOPPASSD=${EPOPPASSD} \ |
23 |
POP_USER=${POP_USER} \ |
22 |
USERS=${USERS} \ |
24 |
POP_GROUP=${POP_GROUP} \ |
23 |
GROUPS=${GROUPS} \ |
25 |
POP_MODE_DIR=${POP_MODE_DIR} \ |
24 |
POP_MODE_DIR=${POP_MODE_DIR} \ |
26 |
POP_MODE_CONF=${POP_MODE_CONF} \ |
25 |
POP_MODE_CONF=${POP_MODE_CONF} \ |
27 |
QPOPAUTH=${QPOPAUTH} |
26 |
QPOPAUTH=${QPOPAUTH} |
Lines 32-44
Link Here
|
32 |
SUB_FILES= pkg-message |
31 |
SUB_FILES= pkg-message |
33 |
# internal configuration |
32 |
# internal configuration |
34 |
POP_USER= pop |
33 |
USERS?= pop |
35 |
POP_GROUP= daemon |
34 |
GROUPS?= daemon |
|
|
35 |
GID_FILES+= ../../GIDs ${.CURDIR}/GIDs |
36 |
POP_MODE_DIR= 0711 |
36 |
POP_MODE_DIR= 0711 |
37 |
POP_MODE_CONF= 0444 |
37 |
POP_MODE_CONF= 0444 |
38 |
POPUSERS_FILE= ${ETCDIR}/popusers |
38 |
POPUSERS_FILE= ${ETCDIR}/popusers |
39 |
SAMPLE_EXT= .sample |
39 |
SAMPLE_EXT= .sample |
40 |
# |
40 |
|
41 |
PKGDEINSTALL= ${PKGINSTALL} |
41 |
PKGDEINSTALL= ${PKGINSTALL} |
42 |
OPTIONS_DEFINE= APOP_ONLY APOP DOCUMENTATION DRAC FULL_POPD_DEBUG PAM \ |
42 |
OPTIONS_DEFINE= APOP_ONLY APOP DOCUMENTATION DRAC FULL_POPD_DEBUG PAM \ |
Lines 68-74
Link Here
|
68 |
QPOPAUTH= "@comment " |
68 |
QPOPAUTH= "@comment " |
69 |
.else |
69 |
.else |
70 |
CONFIGURE_ARGS+= --enable-apop=${ETCDIR}/pop.auth \ |
70 |
CONFIGURE_ARGS+= --enable-apop=${ETCDIR}/pop.auth \ |
71 |
--with-apopuid=pop |
71 |
--with-popuid=${USERS} |
72 |
MAN8+= qpopauth.8 |
72 |
MAN8+= qpopauth.8 |
73 |
QPOPAUTH= "" |
73 |
QPOPAUTH= "" |
74 |
# If WITH_APOP_ONLY variable present in the environment, qpopper builds |
74 |
# If WITH_APOP_ONLY variable present in the environment, qpopper builds |
Lines 81-87
Link Here
|
81 |
# Do not install documentation since it is in pdf format and normally |
81 |
# Do not install documentation since it is in pdf format and normally |
82 |
# not used unless user wants it. |
82 |
# not used unless user wants it. |
83 |
.if empty(PORT_OPTIONS:MDOCUMENTATION) |
83 |
.if empty(PORT_OPTIONS:MDOCUMENTATION) |
84 |
NOPORTDOCS= yes |
84 |
OPTIONS_UNSET+= DOCS |
85 |
.endif |
85 |
.endif |
86 |
# If WITH_DRAC variable present in the environment, qpopper builds |
86 |
# If WITH_DRAC variable present in the environment, qpopper builds |
Lines 128-133
Link Here
|
128 |
# The default is to build without SSL/TLS support. |
128 |
# The default is to build without SSL/TLS support. |
129 |
.if ${PORT_OPTIONS:MSSL} |
129 |
.if ${PORT_OPTIONS:MSSL} |
|
|
130 |
USE_OPENSSL= yes |
130 |
CONFIGURE_ARGS+= --with-openssl=${OPENSSLBASE} |
131 |
CONFIGURE_ARGS+= --with-openssl=${OPENSSLBASE} |
131 |
.endif |
132 |
.endif |
Lines 139-149
Link Here
|
139 |
@${REINPLACE_CMD} -e \ |
140 |
@${REINPLACE_CMD} -e \ |
140 |
's|\$${sbindir}/sendmail|${LOCALBASE}/sbin/sendmail|g' \ |
141 |
's|\$${sbindir}/sendmail|${LOCALBASE}/sbin/sendmail|g' \ |
141 |
${WRKSRC}/configure.in |
142 |
${WRKSRC}/configure.in |
142 |
.if defined(WITH_POPPASSD) |
143 |
.if ${PORT_OPTIONS:MPOPPASSD} |
143 |
@${REINPLACE_CMD} -e 's|/usr/bin/smbpasswd|${LOCALBASE}/bin/smbpasswd|' \ |
144 |
@${REINPLACE_CMD} -e 's|/usr/bin/smbpasswd|${LOCALBASE}/bin/smbpasswd|' \ |
144 |
${WRKSRC}/password/poppassd.c |
145 |
${WRKSRC}/password/poppassd.c |
145 |
.endif |
146 |
.endif |
146 |
.if defined(WITHOUT_U_OPTION) |
147 |
.if empty(PORT_OPTIONS:MU_OPTION) |
147 |
@${REINPLACE_CMD} -E -e 's|(getopt \(.+)u|\1|' \ |
148 |
@${REINPLACE_CMD} -E -e 's|(getopt \(.+)u|\1|' \ |
148 |
${WRKSRC}/popper/main.c |
149 |
${WRKSRC}/popper/main.c |
149 |
.endif |
150 |
.endif |
Lines 152-164
Link Here
|
152 |
@(cd ${WRKSRC}; ${CHMOD} u+w configure*) |
153 |
@(cd ${WRKSRC}; ${CHMOD} u+w configure*) |
153 |
do-install: |
154 |
do-install: |
154 |
.if !defined(WITHOUT_APOP) |
155 |
.if ${PORT_OPTIONS:MAPOP} |
155 |
@${INSTALL_PROGRAM} ${WRKSRC}/popper/popauth ${PREFIX}/bin/qpopauth |
156 |
@${INSTALL_PROGRAM} ${WRKSRC}/popper/popauth ${PREFIX}/bin/qpopauth |
156 |
# If WITHOUT_QPOPAUTH_SETUID variable present in the environment, |
157 |
# If WITHOUT_QPOPAUTH_SETUID variable present in the environment, |
157 |
# qpopper does not install qpopauth setuid to pop user so that |
158 |
# qpopper does not install qpopauth setuid to pop user so that |
158 |
# anyone can access the pop.auth database. |
159 |
# anyone can access the pop.auth database. |
159 |
.if !defined(WITHOUT_QPOPAUTH_SETUID) |
160 |
.if ${PORT_OPTIONS:MQPOPAUTH_SETUID} |
160 |
@${CHOWN} pop ${PREFIX}/bin/qpopauth |
161 |
@${CHOWN} ${USERS} ${PREFIX}/bin/qpopauth |
161 |
@${CHMOD} u+s ${PREFIX}/bin/qpopauth |
162 |
@${CHMOD} u+s ${PREFIX}/bin/qpopauth |
162 |
.endif |
163 |
.endif |
163 |
@${INSTALL_MAN} ${WRKSRC}/man/popauth.8 ${MANPREFIX}/man/man8/qpopauth.8 |
164 |
@${INSTALL_MAN} ${WRKSRC}/man/popauth.8 ${MANPREFIX}/man/man8/qpopauth.8 |
Lines 166-200
Link Here
|
166 |
.endif |
167 |
.endif |
167 |
@${INSTALL_PROGRAM} ${WRKSRC}/popper/popper ${PREFIX}/libexec/qpopper |
168 |
@${INSTALL_PROGRAM} ${WRKSRC}/popper/popper ${PREFIX}/libexec/qpopper |
168 |
@${INSTALL_MAN} ${WRKSRC}/man/popper.8 ${MANPREFIX}/man/man8/qpopper.8 |
169 |
@${INSTALL_MAN} ${WRKSRC}/man/popper.8 ${MANPREFIX}/man/man8/qpopper.8 |
169 |
.if defined(WITH_POPPASSD) |
170 |
.if ${PORT_OPTIONS:MPOPPASSD} |
170 |
@${INSTALL_PROGRAM} ${WRKSRC}/password/poppassd ${PREFIX}/libexec/qpoppassd |
171 |
@${INSTALL_PROGRAM} ${WRKSRC}/password/poppassd ${PREFIX}/libexec/qpoppassd |
171 |
.endif |
172 |
.endif |
172 |
@${INSTALL} -d -o ${POP_USER} -g ${POP_GROUP} -m ${POP_MODE_DIR} \ |
173 |
@${INSTALL} -d -o ${USERS} -g ${GROUPS} -m ${POP_MODE_DIR} \ |
173 |
${ETCDIR} |
174 |
${ETCDIR} |
174 |
.if !defined(NOPORTDOCS) |
175 |
.if ${PORT_OPTIONS:MDOCS} |
175 |
@${MKDIR} ${DOCSDIR} |
176 |
@${MKDIR} ${DOCSDIR} |
176 |
@${INSTALL_DATA} ${WRKSRC}/GUIDE.pdf ${DOCSDIR} |
177 |
@${INSTALL_DATA} ${WRKSRC}/GUIDE.pdf ${DOCSDIR} |
177 |
.endif |
178 |
.endif |
178 |
post-install: install-conf-file |
179 |
post-install: install-conf-file |
179 |
@${CAT} ${PKGMESSAGE} |
180 |
@${CAT} ${PKGMESSAGE} |
|
|
181 |
.if ${PORT_OPTIONS:MPOPPASSD} |
182 |
@${ECHO_MSG} "" |
183 |
@${ECHO_MSG} "===============================================================================" |
184 |
@${ECHO_MSG} "It adds for myself" |
185 |
@${ECHO_MSG} "/etc/devfs.conf:" |
186 |
@${ECHO_MSG} "link /dev/pts/0 pty0" |
187 |
@${ECHO_MSG} "===============================================================================" |
188 |
@${ECHO_MSG} "" |
189 |
.endif |
180 |
# based on original from op port, written by Cyrille Lefevre |
190 |
# based on original from op port, written by Cyrille Lefevre |
181 |
# <clefevre@citeweb.net>. |
191 |
# <clefevre@citeweb.net>. |
182 |
install-conf-file: |
192 |
install-conf-file: |
183 |
@if [ ! -f ${CONF_DIR}/${CONF_FILE}${SAMP_SUFX} ]; then \ |
193 |
@if [ ! -f ${CONF_DIR}/${CONF_FILE}${SAMP_SUFX} ]; then \ |
184 |
if [ -f /etc/ftpusers ] && [ -n "${WITH_SAMPLE_POPUSERS}" ]; then \ |
194 |
if [ -f /etc/ftpusers ] && [ -n "${PORT_OPTIONS:MSAMPLE_POPUSERS}" ]; then \ |
185 |
${INSTALL} -c -o ${POP_USER} -g ${POP_GROUP} -m ${POP_MODE_CONF} \ |
195 |
${INSTALL} -c -o ${USERS} -g ${GROUPS} -m ${POP_MODE_CONF} \ |
186 |
/etc/ftpusers ${POPUSERS_FILE}${SAMPLE_EXT} ; \ |
196 |
/etc/ftpusers ${POPUSERS_FILE}${SAMPLE_EXT} ; \ |
187 |
else \ |
197 |
else \ |
188 |
${CP} /dev/null ${POPUSERS_FILE}${SAMPLE_EXT} ; \ |
198 |
${CP} /dev/null ${POPUSERS_FILE}${SAMPLE_EXT} ; \ |
189 |
${CHOWN} ${POP_USER}:${POP_GROUP} ${POPUSERS_FILE}${SAMPLE_EXT} ; \ |
199 |
${CHOWN} ${USERS}:${GROUPS} ${POPUSERS_FILE}${SAMPLE_EXT} ; \ |
190 |
${CHMOD} ${POP_MODE_CONF} ${POPUSERS_FILE}${SAMPLE_EXT} ; \ |
200 |
${CHMOD} ${POP_MODE_CONF} ${POPUSERS_FILE}${SAMPLE_EXT} ; \ |
191 |
fi ; \ |
201 |
fi ; \ |
192 |
fi |
202 |
fi |
193 |
@${INSTALL} -c -m 0640 \ |
203 |
@${INSTALL} -c -o ${USERS} -g ${GROUPS} -m 0640 \ |
194 |
${WRKSRC}/samples/qpopper.config ${PREFIX}/etc/qpopper.config${SAMPLE_EXT} |
204 |
${WRKSRC}/samples/qpopper.config ${PREFIX}/etc/qpopper.config${SAMPLE_EXT} |
195 |
@${SETENV} PKG_PREFIX=${PREFIX} ${SH} \ |
205 |
@${SETENV} PKG_PREFIX=${PREFIX} ${SH} \ |
196 |
${PKGINSTALL} ${PKGNAME} POST-INSTALL |
206 |
${PKGINSTALL} ${PKGNAME} POST-INSTALL ${USERS} ${GROUPS} |
197 |
.include <bsd.port.post.mk> |
207 |
.include <bsd.port.post.mk> |