diff options
author | bdrewery <bdrewery@FreeBSD.org> | 2014-04-17 13:16:47 +0800 |
---|---|---|
committer | bdrewery <bdrewery@FreeBSD.org> | 2014-04-17 13:16:47 +0800 |
commit | 9dcb907144104328057b76659e92d1fee8d80fbc (patch) | |
tree | 18f9e22e91c3e437d245dba6290079d26f0c1dae /mail | |
parent | 1c7777affab0adb11b83770861eb15e08b950d40 (diff) | |
download | freebsd-ports-gnome-9dcb907144104328057b76659e92d1fee8d80fbc.tar.gz freebsd-ports-gnome-9dcb907144104328057b76659e92d1fee8d80fbc.tar.zst freebsd-ports-gnome-9dcb907144104328057b76659e92d1fee8d80fbc.zip |
mail/qmail, mail/qmail-tls, mail/qmail-mysql, mail/qmail-spamcontrol:
- Support stagedir
- Fix all leftovers
Note that this depends on new Mk/Scripts/check_leftovers.sh added in r351446.
- Bump PORTREVISION in all ports due to plist being fixed.
- Support man.d on FreeBSD 9+
- Convert NOPORTDOCS
- Fix bad perl shebang for scripts/mkaliasdir
- Remove pkg-install and move all to pkg-plist
- Fix /var/qmail modified warning in poudriere by doing nothing in
install-mtree
- Fix /var/qmail getting unpredictable/wrong permissions due to
USERS/GROUPS changing for every user with HOME=/var/qmail
- Use more OPTIONS helpers
- Fix ccache support for spamcontrol patch building
- Fix build of SMTPEXTFORK in mail/qmail-spamcontrol with recent clang
Tested with: pkg and pkg_install
Diffstat (limited to 'mail')
-rw-r--r-- | mail/qmail-mysql/Makefile | 3 | ||||
-rw-r--r-- | mail/qmail-spamcontrol/Makefile | 4 | ||||
-rw-r--r-- | mail/qmail-tls/Makefile | 3 | ||||
-rw-r--r-- | mail/qmail/Makefile | 132 | ||||
-rw-r--r-- | mail/qmail/files/mkaliasdir | 2 | ||||
-rw-r--r-- | mail/qmail/files/pkg-install.in | 34 | ||||
-rw-r--r-- | mail/qmail/files/pkg-message-ldap.in | 6 | ||||
-rw-r--r-- | mail/qmail/files/pkg-message-mysql.in | 6 | ||||
-rw-r--r-- | mail/qmail/files/pkg-message-tls.in | 6 | ||||
-rw-r--r-- | mail/qmail/files/pkg-message.in | 6 | ||||
-rw-r--r-- | mail/qmail/pkg-plist | 110 |
11 files changed, 199 insertions, 113 deletions
diff --git a/mail/qmail-mysql/Makefile b/mail/qmail-mysql/Makefile index 10a0a7343db4..d9f28e545b82 100644 --- a/mail/qmail-mysql/Makefile +++ b/mail/qmail-mysql/Makefile @@ -3,7 +3,7 @@ PORTNAME= qmail PORTVERSION= ${QMAIL_VERSION}.${MYSQL_PATCH_VERSION} -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= mail PKGNAMESUFFIX= -mysql @@ -16,7 +16,6 @@ MYSQL_PATCH_VERSION= 1.1.15 SLAVE_MYSQL= yes USE_MYSQL= yes -NO_STAGE= yes MASTERDIR= ${.CURDIR}/../qmail DESCR= ${.CURDIR}/pkg-descr diff --git a/mail/qmail-spamcontrol/Makefile b/mail/qmail-spamcontrol/Makefile index bd0bb655e031..555287c736fc 100644 --- a/mail/qmail-spamcontrol/Makefile +++ b/mail/qmail-spamcontrol/Makefile @@ -2,7 +2,7 @@ PORTNAME= qmail PORTVERSION= ${QMAIL_VERSION}.${SPAMCONTROL_VERSION} -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= mail MASTER_SITES+= http://www.fehcom.de/qmail/spamcontrol/:spamcontrol \ ${MASTER_SITE_LOCAL:S/$/:spamcontrol/} @@ -15,8 +15,6 @@ COMMENT= Qmail MTA with SpamControl patches CONFLICTS= qmail-[0-9]* qmail-ldap-[0-9]* qmail-mysql-[0-9]* qmail-tls-[0-9]* -NO_STAGE= yes - EXTRA_PATCHES+= ${MASTERDIR}/files/patch-install.c \ ${MASTERDIR}/files/patch-Makefile \ ${MASTERDIR}/files/patch-auto_uids-c-dist diff --git a/mail/qmail-tls/Makefile b/mail/qmail-tls/Makefile index af1934025b64..cb95a55b2d67 100644 --- a/mail/qmail-tls/Makefile +++ b/mail/qmail-tls/Makefile @@ -3,7 +3,7 @@ PORTNAME= qmail PORTVERSION= ${QMAIL_VERSION}.${TLS_PATCH_DATE} -PORTREVISION= 6 +PORTREVISION= 7 CATEGORIES= mail PKGNAMESUFFIX= -tls @@ -15,7 +15,6 @@ SLAVE_TLS= yes TLS_PATCH_DATE= 20021228 -NO_STAGE= yes USE_OPENSSL= yes # Local overrides diff --git a/mail/qmail/Makefile b/mail/qmail/Makefile index 5e284ac6bb0f..f0d1f1a46c4f 100644 --- a/mail/qmail/Makefile +++ b/mail/qmail/Makefile @@ -3,7 +3,7 @@ PORTNAME= qmail PORTVERSION?= ${QMAIL_VERSION} -PORTREVISION?= 8 +PORTREVISION?= 9 CATEGORIES= mail MASTER_SITES+= ${MASTER_SITE_QMAIL} DISTNAME= ${PORTNAME}-${QMAIL_VERSION} @@ -19,13 +19,17 @@ CONFLICTS?= qmail-ldap-[0-9]* qmail-mysql-[0-9]* qmail-spamcontrol-[0-9]* qmail- CONFLICTS+= qmail-vida-[0-9]* USES= qmail:vars -NO_STAGE= yes PREFIX?= ${QMAIL_PREFIX} +PLIST_SUB+= QMAIL_PREFIX="${PREFIX}" MAKE_JOBS_UNSAFE= yes PORTSCOUT= skipv:1.04 +# Need root for build for now due to all of the users/dirs/chmod. Can cleanup +# once pkg_install is EOL. +NEED_ROOT= yes + USERS= alias .for usersuffix in d l p q r s USERS+= ${PORTNAME}${usersuffix} @@ -231,17 +235,19 @@ OPTIONS_DEFINE+=RCDLINK OPTIONS_DEFAULT+= RCDLINK .endif +OPTIONS_SUB= yes + ALL_TARGET+= default dot-qmail.5 qmail-control.5 qmail-getpw.8 \ qmail-limits.7 qmail-newmrh.8 qmail-newu.8 qmail-pw2u.8 \ qmail-send.8 qmail-start.8 qmail-users.5 -MAN1+= forward.1 condredirect.1 bouncesaying.1 except.1 maildirmake.1 \ +MMAN1+= forward.1 condredirect.1 bouncesaying.1 except.1 maildirmake.1 \ maildir2mbox.1 maildirwatch.1 mailsubj.1 qreceipt.1 qbiff.1 preline.1 \ tcp-env.1 -MAN5+= addresses.5 envelopes.5 maildir.5 mbox.5 dot-qmail.5 qmail-control.5 \ +MMAN5+= addresses.5 envelopes.5 maildir.5 mbox.5 dot-qmail.5 qmail-control.5 \ qmail-header.5 qmail-log.5 qmail-users.5 tcp-environ.5 -MAN7+= forgeries.7 qmail-limits.7 qmail.7 -MAN8+= qmail-local.8 qmail-lspawn.8 qmail-getpw.8 qmail-remote.8 \ +MMAN7+= forgeries.7 qmail-limits.7 qmail.7 +MMAN8+= qmail-local.8 qmail-lspawn.8 qmail-getpw.8 qmail-remote.8 \ qmail-rspawn.8 qmail-clean.8 qmail-send.8 qmail-start.8 splogger.8 \ qmail-queue.8 qmail-inject.8 qmail-showctl.8 qmail-newmrh.8 \ qmail-newu.8 qmail-pw2u.8 qmail-qread.8 qmail-qstat.8 qmail-tcpok.8 \ @@ -256,16 +262,17 @@ PKGMESSAGE_SUFFIX= mysql EXTRA_MAN8= qmail-badloadertypes.8 qmail-badmimetypes.8 qmail-mfrules.8 \ qmail-recipients.8 ALL_TARGET+= ${EXTRA_MAN8} -MAN8+= ${EXTRA_MAN8} +MMAN8+= ${EXTRA_MAN8} USES+= perl5 USE_PERL5= patch build .endif .if defined(SLAVE_LDAP) PKGMESSAGE_SUFFIX= ldap -PLIST_SUB+= LDAP="" NOT_LDAP="@comment " +PLIST_SUB+= LDAP="" NO_LDAP="@comment " .else -PLIST_SUB+= LDAP="@comment " NOT_LDAP="" +PLIST_SUB+= LDAP="@comment " NO_LDAP="" +PLIST_SUB+= SRS="@comment " .endif .if defined(SLAVE_SPAMCONTROL) @@ -284,7 +291,7 @@ SLAVEPORT_LINE= ${PKGMESSAGE_SUFFIX} SLAVEPORT_LINE= spamcontrol .endif -SUB_FILES+= mailer.conf.sample bootfiles.sed enable-qmail pkg-install +SUB_FILES+= mailer.conf.sample bootfiles.sed enable-qmail SUB_LIST+= ECHO_CMD=${ECHO_CMD} RCDLINK=${RCDLINK} .if defined(PKGMESSAGE_SUFFIX) @@ -338,29 +345,36 @@ BOOTFILES= home home+df proc proc+df binm1 binm1+df \ binm2 binm2+df binm3 binm3+df maildir .endif -CONFIGUREPROGRAMS= install dnsfq hostname dnsip ipmeprint dnsptr +CONFIGUREPROGRAMS= dnsfq hostname dnsip ipmeprint dnsptr CONFIGURESCRIPTS= config config-fast -.include <bsd.port.options.mk> - -.if defined(SLAVE_LDAP) && ${PORT_OPTIONS:MTLS} -USE_OPENSSL= yes +.if defined(SLAVE_LDAP) +TLS_USE= OPENSSL=yes .endif +# Port will control all PREFIX handling. +install-mtree: + @${DO_NADA} +NO_MTREE= yes +NO_PREFIX_RMDIR=yes + +.include <bsd.port.options.mk> + .include <bsd.port.pre.mk> .if ${PREFIX} != ${LOCALBASE} DOCSDIR= ${PREFIX}/doc .endif -NO_MTREE= yes - .if ${OSVERSION} >= 900007 +SUB_LIST+= MANPATH="@comment " . if defined(SLAVE_LDAP) EXTRA_PATCHES+= ${FILESDIR}/extra-patch-utmpx-ldap . else EXTRA_PATCHES+= ${FILESDIR}/extra-patch-utmpx . endif +.else +SUB_LIST+= MANPATH="" .endif .if defined(SLAVE_TLS) @@ -378,14 +392,8 @@ LDAPFLAGS+= -D${param} . endif . endfor -. if ${PORT_OPTIONS:MEXTERNAL_TODO} -PLIST_SUB+= EXTERNAL_TODO="" -. else -PLIST_SUB+= EXTERNAL_TODO="@comment " -. endif - . if ${PORT_OPTIONS:MSRS} -BUILD_DEPENDS= srs:${PORTSDIR}/mail/libsrs2 +BUILD_DEPENDS+= srs:${PORTSDIR}/mail/libsrs2 MASTER_SITES+= http://qmail-ldap-smtpauthuser.googlecode.com/svn/trunk/:srs_ldap SRS_LDAP_PATCH = qmail-ldap-1.03-20060201-SRS.patch DISTFILES+= ${SRS_LDAP_PATCH}:srs_ldap @@ -524,6 +532,7 @@ PATCHFILES+= tarpit.patch:tarpit ( defined(SLAVE_SPAMCONTROL) || defined(SLAVE_LDAP) ) . if defined(SLAVE_SPAMCONTROL) SMTPEXTFORK_PATCH= smtpextfork-spamcontrol-2519.patch +CFLAGS+= -Wno-return-type . else SMTPEXTFORK_PATCH= smtpextfork-ldap-${LDAP_PATCH_DATE}_4.patch . endif @@ -701,7 +710,7 @@ post-patch: ${ECHO_CMD} "/etc/ssl" > ${UCSPISRC}/src/conf-cadir ${ECHO_CMD} "/etc/ssl/cert.pem" > ${UCSPISRC}/src/conf-cafile ${ECHO_CMD} "/etc/ssl/dh1024.pem" > ${UCSPISRC}/src/conf-dhfile - @cd ${UCSPISRC} && package/compile + @cd ${UCSPISRC} && ${SETENV} ${MAKE_ENV} package/compile @cd ${WRKSRC} && ./install_spamcontrol.sh @${PATCH} -d ${WRKSRC} < ${FILESDIR}/extra-patch-spamcontrol-qmail-smtpd.c @${PATCH} -d ${WRKSRC} < ${FILESDIR}/extra-patch-spamcontrol-qmail-remote.c @@ -791,6 +800,7 @@ post-patch: .endif @${REINPLACE_CMD} -e "s/void *main/int main/g" ${WRKSRC}/*.c @${REINPLACE_CMD} -e "/int main/ s/argc, *argv/int argc, char **argv/" ${WRKSRC}/install.c + @${ECHO_CMD} "MANPATH ${MANPREFIX}/man" > ${WRKDIR}/qmail.conf do-configure: @${ECHO_CMD} "${CC} ${CFLAGS}" > ${WRKSRC}/conf-cc @@ -804,6 +814,15 @@ do-configure: fi .endif +post-build: + @${ECHO_MSG} "===> Rebuilding DJB installer to respect STAGEDIR" + @${MV} -f ${WRKSRC}/conf-qmail ${WRKSRC}/conf-qmail.sav + @${ECHO_CMD} "${STAGEDIR}${PREFIX}" > ${WRKSRC}/conf-qmail + @${MV} -f ${WRKSRC}/install ${WRKSRC}/install.nostage + @cd ${WRKSRC} ; ${RM} -f install instcheck install.o instcheck.o hier.o auto_qmail.o auto_qmail.c + @cd ${WRKSRC} ; ${DO_MAKE_BUILD} install instcheck + @${MV} -f ${WRKSRC}/conf-qmail.sav ${WRKSRC}/conf-qmail + do-install: .for i in ${BOOTFILES} @if [ -f ${WRKSRC}/${i}.sh ] ; then \ @@ -812,54 +831,52 @@ do-install: ${SED} -f ${WRKDIR}/bootfiles.sed ${FILESDIR}/$i > ${WRKDIR}/${i} ; \ fi .endfor - @${MKDIR} ${PREFIX}/configure + @${MKDIR} ${STAGEDIR}${PREFIX}/configure @cd ${WRKSRC} ; ./install .for f in ${CONFIGUREPROGRAMS} - ${INSTALL_PROGRAM} ${WRKSRC}/${f} ${PREFIX}/configure + ${INSTALL_PROGRAM} ${WRKSRC}/${f} ${STAGEDIR}${PREFIX}/configure .endfor + ${INSTALL_PROGRAM} ${WRKSRC}/install.nostage ${STAGEDIR}${PREFIX}/configure/install .for f in ${CONFIGURESCRIPTS} - ${INSTALL_SCRIPT} ${WRKSRC}/${f} ${PREFIX}/configure + ${INSTALL_SCRIPT} ${WRKSRC}/${f} ${STAGEDIR}${PREFIX}/configure .endfor .for i in ${BOOTFILES} - ${INSTALL_SCRIPT} ${WRKDIR}/${i:T} ${PREFIX}/boot + ${INSTALL_SCRIPT} ${WRKDIR}/${i:T} ${STAGEDIR}${PREFIX}/boot .endfor .if !defined(SLAVE_LDAP) - ${INSTALL_SCRIPT} ${WRKDIR}/qmailsmtpd ${PREFIX}/boot + ${INSTALL_SCRIPT} ${WRKDIR}/qmailsmtpd ${STAGEDIR}${PREFIX}/boot .endif .for i in 1 5 7 8 - @${MKDIR} ${PREFIX}/man/man$i -. for j in ${MAN${i}} - ${INSTALL_MAN} ${WRKSRC}/$j ${PREFIX}/man/man${i} + @${MKDIR} ${STAGEDIR}${PREFIX}/man/man$i +. for j in ${MMAN${i}} + ${INSTALL_MAN} ${WRKSRC}/$j ${STAGEDIR}${PREFIX}/man/man${i} . endfor .endfor -.if !defined(NOPORTDOCS) - @${MKDIR} ${DOCSDIR} +.if ${PORT_OPTIONS:MDOCS} + @${MKDIR} ${STAGEDIR}${DOCSDIR} . for sub in WRKSRC WRKDIR WRKDIR_doc . for doc in ${DOCFILES_${sub}} - ${INSTALL_DATA} ${${sub}}/${doc} ${DOCSDIR} + ${INSTALL_DATA} ${${sub}}/${doc} ${STAGEDIR}${DOCSDIR} . endfor . endfor . if ${PORT_OPTIONS:MSMTPEXTFORK} && ( defined(SLAVE_SPAMCONTROL) || defined(SLAVE_LDAP) ) - ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/README.smtpextfork ${DOCSDIR} + ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/README.smtpextfork ${STAGEDIR}${DOCSDIR} . endif . if defined(PACKAGE_BUILDING) @${ECHO_CMD} "FreeBSD Binary package qmail installation" \ - > ${DOCSDIR}/SYSDEPS + > ${STAGEDIR}${DOCSDIR}/SYSDEPS . else @cd ${WRKSRC} && ${CAT} `${CAT} SYSDEPS` \ - > ${DOCSDIR}/SYSDEPS + > ${STAGEDIR}${DOCSDIR}/SYSDEPS . endif .endif - @${MKDIR} ${PREFIX}/scripts - ${INSTALL_SCRIPT} ${FILESDIR}/mkaliasdir ${PREFIX}/scripts - ${INSTALL_SCRIPT} ${WRKDIR}/enable-qmail ${PREFIX}/scripts + @${MKDIR} ${STAGEDIR}${PREFIX}/scripts + ${INSTALL_SCRIPT} ${FILESDIR}/mkaliasdir ${STAGEDIR}${PREFIX}/scripts + ${INSTALL_SCRIPT} ${WRKDIR}/enable-qmail ${STAGEDIR}${PREFIX}/scripts .for script in ${SCRIPTS} - ${INSTALL_SCRIPT} ${WRKDIR}/scripts/${script} ${PREFIX}/scripts + ${INSTALL_SCRIPT} ${WRKDIR}/scripts/${script} ${STAGEDIR}${PREFIX}/scripts .endfor - @${SETENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL - @${ECHO_CMD} - @${CAT} ${PKGMESSAGE} - @${ECHO_CMD} +# @${SETENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL .if defined(SLAVEPORT_LINE) @${ECHO_CMD} "=============================================" @${ECHO_CMD} @@ -872,6 +889,27 @@ do-install: @${ECHO_CMD} .endif +post-install: +.if defined(SLAVE_LDAP) +.for file in qmail-imapd qmail-pop3d qmail-qmqpd qmail-smtpd + @${MV} ${STAGEDIR}${PREFIX}/control/${file}.rules \ + ${STAGEDIR}${PREFIX}/control/${file}.rules.sample +.endfor + @${MV} ${STAGEDIR}${PREFIX}/control/signatures \ + ${STAGEDIR}${PREFIX}/control/signatures.sample + @${FIND} ${WRKDIR} -type f -name run -exec ${SED} -i "" \ + -e 's|${STAGEDIR}|${PREFIX}|' {} + +.endif + @${MKDIR} ${STAGEDIR}${LOCALBASE}/etc/man.d + ${INSTALL_DATA} ${WRKDIR}/qmail.conf ${STAGEDIR}${LOCALBASE}/etc/man.d/qmail.conf + @${ECHO_CMD} "===> Fixing plist for ${PREFIX} ownership" + @{ \ + ${ECHO_CMD} "@owner root"; \ + ${ECHO_CMD} "@group qmail"; \ + ${ECHO_CMD} "@exec install -d -o root -g qmail ${PREFIX}"; \ + ${ECHO_CMD} "@unexec rmdir ${QMAIL_PREFIX} 2>/dev/null || :"; \ + } >> ${TMPPLIST} + certificate: .if defined(SLAVE_TLS) || defined(SLAVE_LDAP) @if [ -f ${OPENSSLDIR}/openssl.cnf ]; then \ diff --git a/mail/qmail/files/mkaliasdir b/mail/qmail/files/mkaliasdir index b380d47d29fd..bb1343ec7b6c 100644 --- a/mail/qmail/files/mkaliasdir +++ b/mail/qmail/files/mkaliasdir @@ -1,4 +1,4 @@ -#!/usr/bin/perl +#!/usr/bin/env perl # # Script to populate a Qmail ~alias directory with entries from # an [SZ]mail{er} or sendmail-like aliases file diff --git a/mail/qmail/files/pkg-install.in b/mail/qmail/files/pkg-install.in deleted file mode 100644 index c533138fb401..000000000000 --- a/mail/qmail/files/pkg-install.in +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh -# -# $FreeBSD$ -# - -export PATH=/bin:/sbin:/usr/bin:/usr/sbin - -PREFIX=${PKG_PREFIX:-%%PREFIX%%} - -if [ "$2" = "POST-INSTALL" ]; then - ${PREFIX}/configure/install x - - [ -e ${PREFIX}/control/me ] || (cd ${PREFIX}/configure && ./config) - - %%RCDLINK%%ln -s ${PREFIX}/rc %%LOCALBASE%%/etc/rc.d/qmailsmtpd - - %%RCDLINK%%echo "" - %%RCDLINK%%echo "A %%LOCALBASE%%/etc/rc.d/qmailsmtpd symlink was created. To enable qmail at boot" - %%RCDLINK%%echo "time you need to copy a script to %%PREFIX%%/rc. There are some examples at" - %%RCDLINK%%echo "%%PREFIX%%/boot" - %%RCDLINK%%echo "" - - if ! touch ${PREFIX}/alias/.qmail-postmaster \ - ${PREFIX}/alias/.qmail-root \ - ${PREFIX}/alias/.qmail-mailer-daemon; then - echo "Failed to create files :" - echo " ${PREFIX}/alias/.qmail-postmaster" - echo " ${PREFIX}/alias/.qmail-root" - echo " ${PREFIX}/alias/.qmail-mailer-daemon" - exit 1 - fi -fi - -exit 0 diff --git a/mail/qmail/files/pkg-message-ldap.in b/mail/qmail/files/pkg-message-ldap.in index c8b3a799bc43..4ec5628ab251 100644 --- a/mail/qmail/files/pkg-message-ldap.in +++ b/mail/qmail/files/pkg-message-ldap.in @@ -1,8 +1,8 @@ ATTENTION: -You should also add %%PREFIX%%/man to your MANPATH (see manpath(1) -or login.conf(5)). - +%%MANPATH%%You should also add %%PREFIX%%/man to your MANPATH (see manpath(1) +%%MANPATH%%or login.conf(5)). +%%MANPATH%% Do not forget to read %%PREFIX%%/doc/QLDAPINSTALL. After all, this is NOT our old stock qmail. And, %%PREFIX%%/doc/ANTISPAM for some antispam control measures. diff --git a/mail/qmail/files/pkg-message-mysql.in b/mail/qmail/files/pkg-message-mysql.in index 47af269db506..f93c92ea0ba4 100644 --- a/mail/qmail/files/pkg-message-mysql.in +++ b/mail/qmail/files/pkg-message-mysql.in @@ -1,8 +1,8 @@ ATTENTION: -You should also add %%PREFIX%%/man to your MANPATH (see manpath(1) -or login.conf(5)). - +%%MANPATH%%You should also add %%PREFIX%%/man to your MANPATH (see manpath(1) +%%MANPATH%%or login.conf(5)). +%%MANPATH%% Do not forget to read http://iain.cx/unix/qmail/mysql.php. After all, this is NOT our old stock qmail. diff --git a/mail/qmail/files/pkg-message-tls.in b/mail/qmail/files/pkg-message-tls.in index b4cec437ec97..d59be8dea289 100644 --- a/mail/qmail/files/pkg-message-tls.in +++ b/mail/qmail/files/pkg-message-tls.in @@ -1,8 +1,8 @@ ATTENTION: -You should also add %%PREFIX%%/man to your MANPATH (see manpath(1) -or login.conf(5)). - +%%MANPATH%%You should also add %%PREFIX%%/man to your MANPATH (see manpath(1) +%%MANPATH%%or login.conf(5)). +%%MANPATH%% Do not forget to read %%PREFIX%%/doc/TLS.readme. After all, this is NOT our old stock qmail. diff --git a/mail/qmail/files/pkg-message.in b/mail/qmail/files/pkg-message.in index c632b2e955b9..d04a1554f839 100644 --- a/mail/qmail/files/pkg-message.in +++ b/mail/qmail/files/pkg-message.in @@ -1,7 +1,7 @@ ATTENTION: -You should also add %%PREFIX%%/man to your MANPATH (see manpath(1) -or login.conf(5)). - +%%MANPATH%%You should also add %%PREFIX%%/man to your MANPATH (see manpath(1) +%%MANPATH%%or login.conf(5)). +%%MANPATH%% You can enable qmail as your default mailer executing: > %%PREFIX%%/scripts/enable-qmail diff --git a/mail/qmail/pkg-plist b/mail/qmail/pkg-plist index cbc12bb05e71..21f6d5dbb73c 100644 --- a/mail/qmail/pkg-plist +++ b/mail/qmail/pkg-plist @@ -1,4 +1,8 @@ +@unexec for alias in postmaster root mailer-daemon; do if [ -f %D/alias/.qmail-${alias} ] && [ $(stat -f '%%z' %D/alias/.qmail-${alias}) -eq 0 ]; then rm -f %D/alias/.qmail-${alias}; fi; done +@exec for alias in postmaster root mailer-daemon; do if ! [ -f %D/alias/.qmail-${alias} ]; then :> %D/alias/.qmail-${alias}; fi; done %%RCDLINK%%@unexec rm -f %%LOCALBASE%%/etc/rc.d/qmailsmtpd +%%RCDLINK%%@exec /bin/ln -fs %D/rc %%LOCALBASE%%/etc/rc.d/qmailsmtpd +%%RCDLINK%%@exec echo; echo "A %%LOCALBASE%%/etc/rc.d/qmailsmtpd symlink was created. To enable qmail at boot time you need to copy a script to %D/rc. There are some examples at %D/boot" | /usr/bin/fmt; echo %%LDAP%%bin/auth_imap %%LDAP%%bin/auth_pop %%LDAP%%bin/auth_smtp @@ -45,7 +49,11 @@ bin/qmail-qmqpd bin/qmail-qmtpd bin/qmail-qread bin/qmail-qstat +@mode 04711 +@owner qmailq bin/qmail-queue +@mode +@owner %%LDAP%%bin/qmail-quotawarn %%SPAMCONTROL%%bin/qmail-recipients bin/qmail-remote @@ -65,19 +73,20 @@ bin/qreceipt bin/qsmhook bin/sendmail bin/splogger +%%SRS%%bin/srsfilter bin/tcp-env -%%NOT_LDAP%%boot/binm1 -%%NOT_LDAP%%boot/binm1+df -%%NOT_LDAP%%boot/binm2 -%%NOT_LDAP%%boot/binm2+df -%%NOT_LDAP%%boot/binm3 -%%NOT_LDAP%%boot/binm3+df -%%NOT_LDAP%%boot/home -%%NOT_LDAP%%boot/home+df -%%NOT_LDAP%%boot/maildir -%%NOT_LDAP%%boot/proc -%%NOT_LDAP%%boot/proc+df -%%NOT_LDAP%%boot/qmailsmtpd +%%NO_LDAP%%boot/binm1 +%%NO_LDAP%%boot/binm1+df +%%NO_LDAP%%boot/binm2 +%%NO_LDAP%%boot/binm2+df +%%NO_LDAP%%boot/binm3 +%%NO_LDAP%%boot/binm3+df +%%NO_LDAP%%boot/home +%%NO_LDAP%%boot/home+df +%%NO_LDAP%%boot/maildir +%%NO_LDAP%%boot/proc +%%NO_LDAP%%boot/proc+df +%%NO_LDAP%%boot/qmailsmtpd %%LDAP%%boot/qmail/log/run %%LDAP%%boot/qmail/run %%LDAP%%boot/qmail-smtpd/log/run @@ -103,12 +112,77 @@ configure/dnsptr configure/hostname configure/install configure/ipmeprint +%%LDAP%%control/Makefile +%%LDAP%%@sample control/qmail-imapd.rules.sample +%%LDAP%%@sample control/qmail-pop3d.rules.sample +%%LDAP%%@sample control/qmail-qmqpd.rules.sample +%%LDAP%%@sample control/qmail-smtpd.rules.sample +%%LDAP%%@sample control/signatures.sample +man/man1/bouncesaying.1.gz +man/man1/condredirect.1.gz +man/man1/except.1.gz +man/man1/forward.1.gz +man/man1/maildir2mbox.1.gz +man/man1/maildirmake.1.gz +man/man1/maildirwatch.1.gz +man/man1/mailsubj.1.gz +man/man1/preline.1.gz +man/man1/qbiff.1.gz +man/man1/qreceipt.1.gz +man/man1/tcp-env.1.gz +man/man5/addresses.5.gz +man/man5/dot-qmail.5.gz +man/man5/envelopes.5.gz +man/man5/maildir.5.gz +man/man5/mbox.5.gz +man/man5/qmail-control.5.gz +man/man5/qmail-header.5.gz +man/man5/qmail-log.5.gz +man/man5/qmail-users.5.gz +man/man5/tcp-environ.5.gz +man/man7/forgeries.7.gz +man/man7/qmail-limits.7.gz +man/man7/qmail.7.gz +man/man8/qmail-clean.8.gz +man/man8/qmail-command.8.gz +man/man8/qmail-getpw.8.gz +man/man8/qmail-inject.8.gz +man/man8/qmail-local.8.gz +man/man8/qmail-lspawn.8.gz +man/man8/qmail-newmrh.8.gz +man/man8/qmail-newu.8.gz +man/man8/qmail-pop3d.8.gz +man/man8/qmail-popup.8.gz +man/man8/qmail-pw2u.8.gz +man/man8/qmail-qmqpc.8.gz +man/man8/qmail-qmqpd.8.gz +man/man8/qmail-qmtpd.8.gz +man/man8/qmail-qread.8.gz +man/man8/qmail-qstat.8.gz +man/man8/qmail-queue.8.gz +man/man8/qmail-remote.8.gz +man/man8/qmail-rspawn.8.gz +man/man8/qmail-send.8.gz +man/man8/qmail-showctl.8.gz +man/man8/qmail-smtpd.8.gz +man/man8/qmail-start.8.gz +man/man8/qmail-tcpok.8.gz +man/man8/qmail-tcpto.8.gz +man/man8/splogger.8.gz +%%SPAMCONTROL%%man/man8/qmail-badloadertypes.8.gz +%%SPAMCONTROL%%man/man8/qmail-badmimetypes.8.gz +%%SPAMCONTROL%%man/man8/qmail-mfrules.8.gz +%%SPAMCONTROL%%man/man8/qmail-recipients.8.gz scripts/enable-qmail scripts/mkaliasdir %%SPAMCONTROL%%scripts/qmail-alias2recipients %%SPAMCONTROL%%scripts/qmail-pwd2recipients %%SPAMCONTROL%%scripts/qmail-users2recipients %%SPAMCONTROL%%scripts/qmail-vpopmail2recipients +@comment Setup non-bin/ dirs (can be removed once pkg_install is EOL) +@exec %D/configure/install x +@comment Do initial config setup if not already done +@exec if ! [ -e %D/control/me ]; then (cd %D/configure && ./config); fi @dirrm bin %%LDAP%%@dirrm boot/qmail/env %%LDAP%%@dirrm boot/qmail/log @@ -145,7 +219,19 @@ scripts/mkaliasdir %%LDAP%%@dirrm log @dirrm boot @dirrm configure +@dirrm man/man1 +@dirrm man/man5 +@dirrm man/man7 +@dirrm man/man8 +@dirrm man @dirrm scripts +@dirrmtry control +@dirrmtry alias +@dirrmtry queue +@dirrmtry users @unexec echo "1) If you are permanently removing qmail, you should also 'rm -rf ${PKG_PREFIX}' and remove the qmail users/groups." | /usr/bin/fmt @unexec echo "2) Do not forget to reconfigure your /etc/mail/mailer.conf to use your older MTA, or reconfigure your old MTA binaries if you decided to replace them." | /usr/bin/fmt @unexec echo "3) Do not forget to enable sendmail as your default MTA if you have to. You can do it just executing 'echo sendmail_enable=\"YES\"' >> /etc/rc.conf" | /usr/bin/fmt +@cwd %%LOCALBASE%% +etc/man.d/qmail.conf +@cwd %%QMAIL_PREFIX%% |