diff options
author | Ashish SHUKLA <ashish@FreeBSD.org> | 2012-05-14 13:12:32 +0000 |
---|---|---|
committer | Ashish SHUKLA <ashish@FreeBSD.org> | 2012-05-14 13:12:32 +0000 |
commit | b9f45c51066ce12dcc33f06245df65a4717bd650 (patch) | |
tree | 797ee8020324b2eca9c9fc14d7a43c602f61071f /mail | |
parent | - Update GStreamer-Qt4 to 0.10.2 release (diff) |
OpenSMTPD is a FREE implementation of the server-side SMTP protocol as
defined by RFC 5321, with some additional standard extensions. It
allows ordinary machines to exchange e-mails with other systems
speaking the SMTP protocol.
WWW: http://www.OpenSMTPD.org/
Notes
Notes:
svn path=/head/; revision=296579
Diffstat (limited to 'mail')
-rw-r--r-- | mail/Makefile | 1 | ||||
-rw-r--r-- | mail/opensmtpd/Makefile | 43 | ||||
-rw-r--r-- | mail/opensmtpd/distinfo | 2 | ||||
-rw-r--r-- | mail/opensmtpd/files/patch-bootstrap | 23 | ||||
-rw-r--r-- | mail/opensmtpd/files/patch-src_Makefile.am | 19 | ||||
-rw-r--r-- | mail/opensmtpd/files/pkg-deinstall.in | 14 | ||||
-rw-r--r-- | mail/opensmtpd/files/pkg-install.in | 17 | ||||
-rw-r--r-- | mail/opensmtpd/files/smtpd.in | 35 | ||||
-rw-r--r-- | mail/opensmtpd/pkg-descr | 6 | ||||
-rw-r--r-- | mail/opensmtpd/pkg-plist | 10 |
10 files changed, 170 insertions, 0 deletions
diff --git a/mail/Makefile b/mail/Makefile index 27474b6b30e4..5248ae55b93e 100644 --- a/mail/Makefile +++ b/mail/Makefile @@ -322,6 +322,7 @@ SUBDIR += nullpop SUBDIR += offlineimap SUBDIR += opendkim + SUBDIR += opensmtpd SUBDIR += openwebmail SUBDIR += osbf-lua SUBDIR += ovs diff --git a/mail/opensmtpd/Makefile b/mail/opensmtpd/Makefile new file mode 100644 index 000000000000..61fe930a090d --- /dev/null +++ b/mail/opensmtpd/Makefile @@ -0,0 +1,43 @@ +# New ports collection makefile for: opensmtpd +# Date created: 2012-05-13 +# Whom: Ashish SHUKLA <ashish@FreeBSD.org> +# +# $FreeBSD$ +# + +PORTNAME= opensmtpd +PORTVERSION= 201205011446 +CATEGORIES= mail +MASTER_SITES= http://www.opensmtpd.org/archives/ + +MAINTAINER= ashish@FreeBSD.org +COMMENT= OpenSMTPD is a free MTA + +LIB_DEPENDS= event-1.4:${PORTSDIR}/devel/libevent + +LICENSE_NAME= ISCL + +WRKSRC= ${WRKDIR}/${PORTNAME} + +USE_AUTOTOOLS= autoconf:env automake:env libtool:env +GNU_CONFIGURE= yes +CONFIGURE_ARGS= --with-libevent-dir=${LOCALBASE} + +USE_RC_SUBR= smtpd +SUB_FILES= pkg-install pkg-deinstall + +CONFLICTS= postfix-[0-9]* sendmail-[0-9]* + +MAN8= makemap.8 newaliases.8 smtpctl.8 smtpd.8 +MAN5= smtpd.conf.5 + +pre-configure: + @cd ${WRKSRC} && ./bootstrap + +post-install: + @${SETENV} ${SCRIPTS_ENV} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL + +post-deinstall: + @${SETENV} ${SCRIPTS_ENV} ${SH} ${PKGINSTALL} ${PKGNAME} POST-DEINSTALL + +.include <bsd.port.mk> diff --git a/mail/opensmtpd/distinfo b/mail/opensmtpd/distinfo new file mode 100644 index 000000000000..d0d6c225e857 --- /dev/null +++ b/mail/opensmtpd/distinfo @@ -0,0 +1,2 @@ +SHA256 (opensmtpd-201205011446.tar.gz) = dbeb4139e1a949a535e71627d54de117af7eef5163e158f98ecba5fcf6c1b441 +SIZE (opensmtpd-201205011446.tar.gz) = 224987 diff --git a/mail/opensmtpd/files/patch-bootstrap b/mail/opensmtpd/files/patch-bootstrap new file mode 100644 index 000000000000..6a7ad2c4528e --- /dev/null +++ b/mail/opensmtpd/files/patch-bootstrap @@ -0,0 +1,23 @@ + +$FreeBSD$ + +--- bootstrap.orig ++++ bootstrap +@@ -36,7 +36,7 @@ + + # Check for automake + amvers="no" +-for v in 11 10 9 8 7 6 5; do ++for v in 12 11 10 9 8 7 6 5; do + if automake-1.${v} --version >/dev/null 2>&1; then + amvers="-1.${v}" + break +@@ -62,7 +62,7 @@ + + # Check for autoconf + acvers="no" +-for v in "259" "-2.59" "253" "-2.53" ""; do ++for v in "269" "-2.69" "259" "-2.59" "253" "-2.53" ""; do + if autoconf${v} --version >/dev/null 2>&1; then + acvers="${v}" + break diff --git a/mail/opensmtpd/files/patch-src_Makefile.am b/mail/opensmtpd/files/patch-src_Makefile.am new file mode 100644 index 000000000000..f11e966cb380 --- /dev/null +++ b/mail/opensmtpd/files/patch-src_Makefile.am @@ -0,0 +1,19 @@ + +$FreeBSD$ + +--- src/Makefile.am.orig ++++ src/Makefile.am +@@ -107,10 +107,10 @@ + $(MKDIR_P) $(DESTDIR)$(mandir)/$(mansubdir)5 + $(MKDIR_P) $(DESTDIR)$(mandir)/$(mansubdir)8 + +- @if [ ! -f $(DESTDIR)$(sysconfdir)/mail/smtpd.conf ]; then \ +- $(INSTALL) -m 644 smtpd.conf.out $(DESTDIR)$(sysconfdir)/mail/smtpd.conf; \ ++ @if [ ! -f $(DESTDIR)$(sysconfdir)/mail/smtpd.conf.sample ]; then \ ++ $(INSTALL) -m 644 smtpd.conf.out $(DESTDIR)$(sysconfdir)/mail/smtpd.conf.sample; \ + else \ +- echo "$(DESTDIR)$(sysconfdir)/mail/smtpd.conf already exists, install will not overwrite"; \ ++ echo "$(DESTDIR)$(sysconfdir)/mail/smtpd.conf.sample already exists, install will not overwrite"; \ + fi + + @if [ ! -f $(DESTDIR)$(bindir)/mailq$(EXEEXT) ]; then \ diff --git a/mail/opensmtpd/files/pkg-deinstall.in b/mail/opensmtpd/files/pkg-deinstall.in new file mode 100644 index 000000000000..b25dc20267aa --- /dev/null +++ b/mail/opensmtpd/files/pkg-deinstall.in @@ -0,0 +1,14 @@ +#!/bin/sh + +PKGNAME=$1 +TARGET=$2 + +PREFIX=$(echo %%PREFIX%% |sed -e 's,/,\\/,g') + +if [ "$TARGET" = POST-DEINSTALL ]; then + sed -e '/[[:space:]]'$PREFIX'\/sbin\/smtpctl/d' \ + -e '/[[:space:]]'$PREFIX'\/libexec\/opensmtpd-portable\/makemap/d' \ + -e 's/^### smtpd: //g' -i '' /etc/mail/mailer.conf +fi + +exit 0 diff --git a/mail/opensmtpd/files/pkg-install.in b/mail/opensmtpd/files/pkg-install.in new file mode 100644 index 000000000000..c54f17a07499 --- /dev/null +++ b/mail/opensmtpd/files/pkg-install.in @@ -0,0 +1,17 @@ +#!/bin/sh + +PKGNAME=$1 +TARGET=$2 + +if [ "$TARGET" = POST-INSTALL ]; then + sed -e '/^[^#]/s/^/### smtpd: /g' -i '' /etc/mail/mailer.conf + cat >>/etc/mail/mailer.conf <<EOF +sendmail %%PREFIX%%/sbin/smtpctl +send-mail %%PREFIX%%/sbin/smtpctl +mailq %%PREFIX%%/sbin/smtpctl +makemap %%PREFIX%%/libexec/opensmtpd-portable/makemap +newaliases %%PREFIX%%/libexec/opensmtpd-portable/makemap +EOF +fi + +exit 0 diff --git a/mail/opensmtpd/files/smtpd.in b/mail/opensmtpd/files/smtpd.in new file mode 100644 index 000000000000..a0801b76d95c --- /dev/null +++ b/mail/opensmtpd/files/smtpd.in @@ -0,0 +1,35 @@ +#!/bin/sh +# +# $FreeBSD$ +# +# PROVIDE: smtpd mail +# REQUIRE: %%REQUIRE%% +# KEYWORD: shutdown +# +# Add the following lines to /etc/rc.conf to enable smtpd: +# smtpd_enable (bool): Set it to "YES" to enable postfix. +# Default is "NO". +# smtpd_config (string): Path to OpenSMTPD configuration file. +# Default is "%%PREFIX%%/etc/mail/smtpd.conf" +# smtpd_flags (string): Additional flags to be passed to smtpd. +# Default is "". +# +# + +. /etc/rc.subr + +name="smtpd" +rcvar=smtpd_enable + +load_rc_config $name + +: ${smtpd_enable:="NO"} +: ${smtpd_config:="%%PREFIX%%/etc/mail/smtpd.conf"} +: ${smtpd_procname:="%%PREFIX%%/sbin/smtpd"} +: ${smtpd_flags:=""} + +command=${smtpd_procname} + +procname=${smtpd_procname} + +run_rc_command "$1" diff --git a/mail/opensmtpd/pkg-descr b/mail/opensmtpd/pkg-descr new file mode 100644 index 000000000000..f5bcb42c0cb2 --- /dev/null +++ b/mail/opensmtpd/pkg-descr @@ -0,0 +1,6 @@ +OpenSMTPD is a FREE implementation of the server-side SMTP protocol as +defined by RFC 5321, with some additional standard extensions. It +allows ordinary machines to exchange e-mails with other systems +speaking the SMTP protocol. + +WWW: http://www.OpenSMTPD.org/ diff --git a/mail/opensmtpd/pkg-plist b/mail/opensmtpd/pkg-plist new file mode 100644 index 000000000000..01ab9a8d124d --- /dev/null +++ b/mail/opensmtpd/pkg-plist @@ -0,0 +1,10 @@ +bin/mailq +bin/newaliases +etc/mail/smtpd.conf.sample +libexec/mail.local +libexec/opensmtpd-portable/makemap +sbin/makemap +sbin/smtpctl +sbin/smtpd +@dirrm libexec/opensmtpd-portable +@dirrmtry etc/mail |